|
4 | 4 |
|
5 | 5 | set -euo pipefail |
6 | 6 |
|
7 | | -. /opt/conda/etc/profile.d/conda.sh |
8 | | - |
9 | | -rapids-logger "Install testing dependencies" |
10 | | -# TODO: Replace with rapids-dependency-file-generator |
11 | | -DEPENDENCIES=( |
12 | | - "psutil" |
13 | | - "pytest" |
14 | | - "pytest-xdist" |
15 | | - "pytest-benchmark" |
16 | | - "cffi" |
17 | | - "ml_dtypes" |
18 | | - "python=${RAPIDS_PY_VERSION}" |
19 | | - "numba-cuda" |
20 | | -) |
21 | | -rapids-mamba-retry create \ |
22 | | - -n test \ |
23 | | - --strict-channel-priority \ |
24 | | - --channel "`pwd`/conda-repo" \ |
25 | | - --channel conda-forge \ |
26 | | - "${DEPENDENCIES[@]}" |
27 | | - |
28 | | -# Temporarily allow unbound variables for conda activation. |
29 | | -set +u |
30 | | -conda activate test |
31 | | -set -u |
32 | | - |
33 | | -pip install filecheck |
34 | | - |
35 | | -rapids-print-env |
36 | | - |
37 | | -# The simulator doesn't actually use the test binaries, but we move into the |
38 | | -# test binaries folder so that we're not in the root of the repo, and therefore |
39 | | -# numba-cuda code from the installed package will be tested, instead of the |
40 | | -# code in the source repo. |
41 | | -rapids-logger "Move to test binaries folder" |
42 | | -export NUMBA_CUDA_TEST_BIN_DIR=`pwd`/testing |
43 | | -pushd $NUMBA_CUDA_TEST_BIN_DIR |
44 | | - |
45 | | -rapids-logger "Show Numba system info" |
46 | | -python -m numba --sysinfo |
47 | | - |
48 | 7 | EXITCODE=0 |
49 | 8 | trap "EXITCODE=1" ERR |
50 | 9 | set +e |
51 | 10 |
|
52 | | -rapids-logger "Run Tests" |
53 | | -export NUMBA_ENABLE_CUDASIM=1 |
54 | | -pytest -v |
| 11 | +rapids-logger "Show Numba system info" |
| 12 | +pixi run -e "${PIXI_ENV}" python -m numba --sysinfo |
| 13 | + |
| 14 | +rapids-logger "Test importing numba.cuda" |
| 15 | +pixi run -e "${PIXI_ENV}" python -c "from numba import cuda" |
55 | 16 |
|
56 | | -popd |
| 17 | +rapids-logger "Run Tests" |
| 18 | +pixi run -e "${PIXI_ENV}" simtest -n auto \ |
| 19 | + --dist loadscope \ |
| 20 | + --loadscope-reorder \ |
| 21 | + --benchmark-disable -v |
57 | 22 |
|
58 | 23 | rapids-logger "Test script exiting with value: $EXITCODE" |
59 | 24 | exit ${EXITCODE} |
0 commit comments