diff --git a/.github/template/fwe-build/action.yml b/.github/template/fwe-build/action.yml index d0679e5..fc17874 100644 --- a/.github/template/fwe-build/action.yml +++ b/.github/template/fwe-build/action.yml @@ -62,7 +62,7 @@ runs: shell: bash if: inputs.build-arch == 'native' run: | - ./tools/test-fwe.sh ${{ inputs.extra-options }} --extra-ctest-args "-E \"CANDataSourceTest|ISOTPOverCANProtocolTest|IoTFleetWiseEngineTest|OBDOverCANModuleTest\"" + ./tools/test-fwe.sh ${{ inputs.extra-options }} --extra-gtest-filter "-*CANDataSourceTest*:*ISOTPOverCANProtocolTest*:*IoTFleetWiseEngineTest*:*OBDOverCANModuleTest*" - name: upload-artifacts uses: actions/upload-artifact@v4 diff --git a/tools/test-fwe.sh b/tools/test-fwe.sh index bc510fa..a30a391 100755 --- a/tools/test-fwe.sh +++ b/tools/test-fwe.sh @@ -5,23 +5,22 @@ set -eo pipefail WITH_ROS2_SUPPORT="false" -EXTRA_CTEST_ARGS="" +EXTRA_GTEST_FILTER="*" parse_args() { while [ "$#" -gt 0 ]; do case $1 in --with-ros2-support) WITH_ROS2_SUPPORT="true" - shift ;; - --extra-ctest-args) - EXTRA_CTEST_ARGS=$2 + --extra-gtest-filter) + EXTRA_GTEST_FILTER=$2 shift ;; --help) echo "Usage: $0 [OPTION]" echo " --with-ros2-support Test with ROS2 support" - echo " --extra-ctest-args Args to be passed to ctest eg. -E " + echo " --extra-gtest-filter Regex to set for gtest filter eg. '-**' or '**'" exit 0 ;; esac @@ -37,4 +36,4 @@ if ${WITH_ROS2_SUPPORT}; then else cd build fi -ctest -V ${EXTRA_CTEST_ARGS} +GTEST_FILTER=${EXTRA_GTEST_FILTER} ctest -V