Skip to content

Commit fa0b9a6

Browse files
committed
chore: move simulator to pixi
1 parent fa88b75 commit fa0b9a6

File tree

1 file changed

+10
-45
lines changed

1 file changed

+10
-45
lines changed

ci/test_simulator.sh

Lines changed: 10 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -4,56 +4,21 @@
44

55
set -euo pipefail
66

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-
487
EXITCODE=0
498
trap "EXITCODE=1" ERR
509
set +e
5110

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"
5516

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
5722

5823
rapids-logger "Test script exiting with value: $EXITCODE"
5924
exit ${EXITCODE}

0 commit comments

Comments
 (0)