62
62
TEST_CUDA_MAJOR="$(cut -d '.' -f 1 <<< ${{ inputs.cuda-version }})"
63
63
if [[ $BUILD_CUDA_MAJOR != $TEST_CUDA_MAJOR ]]; then
64
64
SKIP_CUDA_BINDINGS_TEST=1
65
+ SKIP_CUDA_CORE_CYTHON_TEST=0
65
66
else
66
67
SKIP_CUDA_BINDINGS_TEST=0
68
+ BUILD_CUDA_MINOR="$(cut -d '.' -f 2 <<< ${{ inputs.build-ctk-ver }})"
69
+ TEST_CUDA_MINOR="$(cut -d '.' -f 2 <<< ${{ inputs.cuda-version }})"
70
+ if [[ $BUILD_CUDA_MINOR != $TEST_CUDA_MINOR ]]; then
71
+ SKIP_CUDA_CORE_CYTHON_TEST=1
72
+ else
73
+ SKIP_CUDA_CORE_CYTHON_TEST=0
74
+ fi
67
75
fi
68
76
69
77
# make outputs from the previous job as env vars
77
85
echo "CUDA_BINDINGS_ARTIFACT_NAME=${CUDA_BINDINGS_ARTIFACT_BASENAME}-${{ github.sha }}" >> $GITHUB_ENV
78
86
echo "CUDA_BINDINGS_ARTIFACTS_DIR=$(realpath "$REPO_DIR/cuda_bindings/dist")" >> $GITHUB_ENV
79
87
echo "SKIP_CUDA_BINDINGS_TEST=${SKIP_CUDA_BINDINGS_TEST}" >> $GITHUB_ENV
88
+ echo "SKIP_CUDA_CORE_CYTHON_TEST=${SKIP_CUDA_CORE_CYTHON_TEST}" >> $GITHUB_ENV
80
89
81
90
- name : Install dependencies
82
91
uses : ./.github/actions/install_unix_deps
@@ -197,8 +206,8 @@ jobs:
197
206
exit 1
198
207
fi
199
208
pytest -rxXs tests/cython
200
- popd
201
209
fi
210
+ popd
202
211
203
212
- name : Run cuda.core tests
204
213
run : |
@@ -221,20 +230,22 @@ jobs:
221
230
pushd ./cuda_core
222
231
pip install -r "tests/requirements-cu${TEST_CUDA_MAJOR}.txt"
223
232
pytest -rxXs tests/
224
- popd
225
233
226
234
# It is a bit convoluted to run the Cython tests against CTK wheels,
227
- # so let's just skip them.
228
- if [[ "${{ inputs.local-ctk }}" == 1 ]]; then
235
+ # so let's just skip them. Also, currently our CI always installs the
236
+ # latest bindings (from either major version). This is not compatible
237
+ # with the test requirements.
238
+ if [[ "${{ inputs.local-ctk }}" == 1 && "${SKIP_CUDA_CORE_CYTHON_TEST}" == 0 ]]; then
239
+ pip install cython
229
240
if [[ "${{ inputs.host-platform }}" == linux* ]]; then
230
241
bash tests/cython/build_tests.sh
231
242
elif [[ "${{ inputs.host-platform }}" == win* ]]; then
232
243
# TODO: enable this once win-64 runners are up
233
244
exit 1
234
245
fi
235
246
pytest -rxXs tests/cython
236
- popd
237
247
fi
248
+ popd
238
249
239
250
- name : Ensure cuda-python installable
240
251
run : |
0 commit comments