Update CI with testing framework from eigen_ci_cross_testing.

This commit is contained in:
Antonio Sánchez
2024-01-19 17:55:09 +00:00
committed by Rasmus Munk Larsen
parent b2814d53a7
commit 34fd46a9b4
21 changed files with 1208 additions and 504 deletions

View File

@@ -0,0 +1,28 @@
#!/bin/bash
set -x
# Enter build directory.
rootdir=`pwd`
cd ${EIGEN_CI_BUILDDIR}
target=""
if [[ ${EIGEN_CI_TEST_REGEX} ]]; then
target="-R ${EIGEN_CI_TEST_REGEX}"
elif [[ ${EIGEN_CI_TEST_LABEL} ]]; then
target="-L ${EIGEN_CI_TEST_LABEL}"
fi
# Repeat tests up to three times to ignore flakes. Do not re-run with -T test,
# otherwise we lose test results for those that passed.
# Note: starting with CMake 3.17, we can use --repeat until-pass:3, but we have
# no way of easily installing this on ppc64le.
ctest --parallel ${NPROC} --output-on-failure --no-compress-output \
--build-no-clean -T test ${target} || \
ctest -j${NPROC} --output-on-failure --no-compress-output --rerun-failed || \
ctest -j${NPROC} --output-on-failure --no-compress-output --rerun-failed
# Return to root directory.
cd ${rootdir}
set +x