Skip to content

Commit d8b7dac

Browse files
authored
Run examples in CI (rapidsai#1850)
This PR runs C++ examples in CI. Closes rapidsai#1845. Authors: - Bradley Dice (https://github.com/bdice) Approvers: - James Lamb (https://github.com/jameslamb) URL: rapidsai#1850
1 parent 866a40e commit d8b7dac

File tree

3 files changed

+20
-0
lines changed

3 files changed

+20
-0
lines changed

ci/release/update-version.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ done
5050
DEPENDENCIES=(
5151
librmm
5252
librmm-tests
53+
librmm-example
5354
rmm
5455
)
5556
for DEP in "${DEPENDENCIES[@]}"; do

ci/test_cpp.sh

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,5 +38,18 @@ rapids-logger "Run gtests"
3838
export GTEST_OUTPUT=xml:${RAPIDS_TESTS_DIR}/
3939
./ci/run_ctests.sh -j20 && EXITCODE=$? || EXITCODE=$?;
4040

41+
# Run all examples from librmm-example package
42+
for example in ${CONDA_PREFIX}/bin/examples/librmm/*; do
43+
if [ -x "$example" ]; then
44+
rapids-logger "Running example: $(basename "$example")"
45+
"$example" && EXAMPLE_EXITCODE=$? || EXAMPLE_EXITCODE=$?;
46+
if [ $EXAMPLE_EXITCODE -ne 0 ]; then
47+
rapids-logger "Example $(basename "$example") failed with exit code: $EXAMPLE_EXITCODE"
48+
EXITCODE=$EXAMPLE_EXITCODE
49+
break
50+
fi
51+
fi
52+
done
53+
4154
rapids-logger "Test script exiting with value: $EXITCODE"
4255
exit "${EXITCODE}"

dependencies.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ files:
3333
- test_cpp
3434
- depends_on_librmm
3535
- depends_on_librmm_tests
36+
- depends_on_librmm_example
3637
checks:
3738
output: none
3839
includes:
@@ -223,6 +224,11 @@ dependencies:
223224
- output_types: conda
224225
packages:
225226
- librmm-tests=25.4.*,>=0.0.0a0
227+
depends_on_librmm_example:
228+
common:
229+
- output_types: conda
230+
packages:
231+
- librmm-example=25.4.*,>=0.0.0a0
226232
checks:
227233
common:
228234
- output_types: [conda, requirements]

0 commit comments

Comments
 (0)