@@ -182,7 +182,6 @@ jobs:
182182 # Note: this is for test-time only.
183183 - " 12.6.2"
184184 - " 12.0.1"
185- # FIXME: cannot run cuda.bindings 12.x with CTK 11.x
186185 - " 11.8.0"
187186 runner :
188187 - default
@@ -232,7 +231,7 @@ jobs:
232231
233232 BUILD_CUDA_MAJOR="$(cut -d '.' -f 1 <<< ${{ needs.build.outputs.BUILD_CTK_VER }})"
234233 TEST_CUDA_MAJOR="$(cut -d '.' -f 1 <<< ${{ matrix.cuda-version }})"
235- if [[ $BUILD_CUDA_MAJOR -gt $TEST_CUDA_MAJOR ]]; then
234+ if [[ $BUILD_CUDA_MAJOR != $TEST_CUDA_MAJOR ]]; then
236235 SKIP_CUDA_BINDINGS_TEST=1
237236 else
238237 SKIP_CUDA_BINDINGS_TEST=0
@@ -306,18 +305,20 @@ jobs:
306305 if [[ ${{ matrix.python-version }} == "3.13" ]]; then
307306 echo "Python 3.13 + cuda-python ${{ matrix.cuda-version }} is not supported, skipping the test..."
308307 exit 0
309- else
310- pip install "cuda-python==$(cut -d '.' -f 1,2 <<< ${{ matrix.cuda-version }}).*"
311308 fi
312309 fi
313310
311+ # If build/test majors match: cuda.bindings is installed in the previous step.
312+ # If mismatch: cuda.bindings is installed from PyPI.
313+ TEST_CUDA_MAJOR="$(cut -d '.' -f 1 <<< ${{ matrix.cuda-version }})"
314314 pushd "${CUDA_CORE_ARTIFACTS_DIR}"
315- pip install *.whl
315+ pip install $(ls *.whl)["cu${TEST_CUDA_MAJOR}"]
316316 popd
317317
318318 pushd ./cuda_core
319319 # TODO: add requirements.txt for test deps?
320- # TODO: add cupy as an optional test dep?
321320 pip install pytest
321+ # TODO: add CuPy to test deps (which would require cuRAND)
322+ # pip install "cupy-cuda${TEST_CUDA_MAJOR}x"
322323 pytest -rxXs tests/
323324 popd
0 commit comments