File: python_tests.yml

package info (click to toggle)
xgboost 3.0.4-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 13,848 kB
  • sloc: cpp: 67,603; python: 35,537; java: 4,676; ansic: 1,426; sh: 1,352; xml: 1,226; makefile: 204; javascript: 19
file content (64 lines) | stat: -rw-r--r-- 1,891 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
name: XGBoost CI (Python tests)

on: [push, pull_request]

permissions:
  contents: read # to fetch code (actions/checkout)

defaults:
  run:
    shell: bash -l {0}

concurrency:
  group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
  cancel-in-progress: true

jobs:
  python-sdist-test:
    runs-on: ${{ matrix.os }}
    name: Test installing Python XGBoost from the source distribution (${{ matrix.os }})
    strategy:
      fail-fast: false
      matrix:
        os: [macos-13, windows-latest, ubuntu-latest]
    steps:
      - uses: actions/checkout@v4
        with:
          submodules: 'true'
      - uses: dmlc/xgboost-devops/actions/miniforge-setup@main
        with:
          environment-name: sdist_test
          environment-file: ops/conda_env/sdist_test.yml
      - name: Install extra package for MacOS
        run: |
          mamba install -c conda-forge llvm-openmp
        if: matrix.os == 'macos-13'
      - name: Build and install XGBoost
        run: bash ops/pipeline/test-python-sdist.sh

  python-tests-on-macos:
    name: Test XGBoost Python package on macos-13
    runs-on: macos-13
    timeout-minutes: 60
    steps:
      - uses: actions/checkout@v4
        with:
          submodules: 'true'
      - uses: dmlc/xgboost-devops/actions/miniforge-setup@main
        with:
          environment-name: macos_cpu_test
          environment-file: ops/conda_env/macos_cpu_test.yml
      - run: bash ops/pipeline/test-python-macos.sh

  python-system-installation-on-ubuntu:
    name: Test XGBoost Python package System Installation on Ubuntu
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
        with:
          submodules: 'true'
      - name: Set up Python 3.10
        uses: actions/setup-python@v5
        with:
          python-version: "3.10"
      - run: bash ops/pipeline/test-python-with-sysprefix.sh