Skip to content

Improve ctest label exclusion, drop cppcheck on RHEL#567

Merged
cottsay merged 2 commits intomasterfrom
cottsay/ctest_labels
May 5, 2021
Merged

Improve ctest label exclusion, drop cppcheck on RHEL#567
cottsay merged 2 commits intomasterfrom
cottsay/ctest_labels

Conversation

@cottsay
Copy link
Member

@cottsay cottsay commented Apr 13, 2021

The existing ctest label exclusion modifiers relied on the default exclusion always being xfail. In order to exclude cppcheck on RHEL builds, that logic needed to be improved. This change uses a simple regex to allow the default to be something else.

Details
$ ./create_jenkins_job.py
Connecting to Jenkins 'https://ci.ros2.org'
Connected to Jenkins version '2.263.4'
Skipped 'ci_linux' because the config is the same (dry run)
Skipped 'test_ci_linux' because the config is the same (dry run)
Skipped 'ci_packaging_linux' because the config is the same (dry run)
Skipped 'packaging_linux' because the config is the same (dry run)
Skipped 'nightly_linux_debug' because the config is the same (dry run)
Skipped 'nightly_linux_address_sanitizer' because the config is the same (dry run)
Skipped 'nightly_linux_clang_libcxx' because the config is the same (dry run)
Skipped 'ci_linux_clang_libcxx' because the config is the same (dry run)
Skipped 'nightly_linux_thread_sanitizer' because the config is the same (dry run)
Skipped 'ci_linux_coverage' because the config is the same (dry run)
Skipped 'test_linux_coverage' because the config is the same (dry run)
Skipped 'nightly_linux_coverage' because the config is the same (dry run)
Skipped 'nightly_linux_foxy_coverage' because the config is the same (dry run)
Skipped 'nightly_linux_release' because the config is the same (dry run)
Skipped 'nightly_linux_repeated' because the config is the same (dry run)
Skipped 'nightly_linux_xfail' because the config is the same (dry run)
Skipped 'ci_linux-aarch64' because the config is the same (dry run)
Skipped 'test_ci_linux-aarch64' because the config is the same (dry run)
Skipped 'ci_packaging_linux-aarch64' because the config is the same (dry run)
Skipped 'packaging_linux-aarch64' because the config is the same (dry run)
Skipped 'nightly_linux-aarch64_debug' because the config is the same (dry run)
Skipped 'nightly_linux-aarch64_release' because the config is the same (dry run)
Skipped 'nightly_linux-aarch64_repeated' because the config is the same (dry run)
Skipped 'nightly_linux-aarch64_xfail' because the config is the same (dry run)
Skipped 'ci_linux-armhf' because the config is the same (dry run)
Skipped 'test_ci_linux-armhf' because the config is the same (dry run)
Skipped 'ci_packaging_linux-armhf' because the config is the same (dry run)
Skipped 'packaging_linux-armhf' because the config is the same (dry run)
Updating job 'ci_linux-rhel' (dry run)
    <<<
    --- remote config
    +++ new config
    @@ -166 +166 @@
    -          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE xfail --pytest-args -m "not xfail"</defaultValue>
    +          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE "(cppcheck|xfail)" --pytest-args -m "not xfail"</defaultValue>
    >>>
Updating job 'test_ci_linux-rhel' (dry run)
    <<<
    --- remote config
    +++ new config
    @@ -166 +166 @@
    -          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE xfail --pytest-args -m "not xfail"</defaultValue>
    +          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE "(cppcheck|xfail)" --pytest-args -m "not xfail"</defaultValue>
    >>>
Updating job 'ci_packaging_linux-rhel' (dry run)
    <<<
    --- remote config
    +++ new config
    @@ -158 +158 @@
    -          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE xfail --pytest-args -m "not xfail"</defaultValue>
    +          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE "(cppcheck|xfail)" --pytest-args -m "not xfail"</defaultValue>
    >>>
Updating job 'packaging_linux-rhel' (dry run)
    <<<
    --- remote config
    +++ new config
    @@ -158 +158 @@
    -          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE xfail --pytest-args -m "not xfail"</defaultValue>
    +          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE "(cppcheck|xfail)" --pytest-args -m "not xfail"</defaultValue>
    >>>
Updating job 'nightly_linux-rhel_debug' (dry run)
    <<<
    --- remote config
    +++ new config
    @@ -166 +166 @@
    -          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE xfail --pytest-args -m "not xfail"</defaultValue>
    +          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE "(cppcheck|xfail)" --pytest-args -m "not xfail"</defaultValue>
    >>>
Updating job 'nightly_linux-rhel_release' (dry run)
    <<<
    --- remote config
    +++ new config
    @@ -166 +166 @@
    -          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE xfail --pytest-args -m "not xfail"</defaultValue>
    +          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-pass 2 --ctest-args -LE "(cppcheck|xfail)" --pytest-args -m "not xfail"</defaultValue>
    >>>
Updating job 'nightly_linux-rhel_repeated' (dry run)
    <<<
    --- remote config
    +++ new config
    @@ -166 +166 @@
    -          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-fail 2 --ctest-args -LE "(linter|xfail)" --pytest-args -m "not linter and not xfail"</defaultValue>
    +          <defaultValue>--packages-skip-by-dep ros1_bridge --packages-skip ros1_bridge --event-handlers console_direct+ --executor sequential --retest-until-fail 2 --ctest-args -LE "(linter|(cppcheck|xfail))" --pytest-args -m "not linter and not xfail"</defaultValue>
    >>>
Skipped 'nightly_linux-rhel_xfail' because the config is the same (dry run)
Skipped 'ci_osx' because the config is the same (dry run)
Skipped 'test_ci_osx' because the config is the same (dry run)
Skipped 'ci_packaging_osx' because the config is the same (dry run)
Skipped 'packaging_osx' because the config is the same (dry run)
Skipped 'nightly_osx_debug' because the config is the same (dry run)
Skipped 'nightly_osx_release' because the config is the same (dry run)
Skipped 'nightly_osx_repeated' because the config is the same (dry run)
Skipped 'nightly_osx_xfail' because the config is the same (dry run)
Skipped 'ci_windows' because the config is the same (dry run)
Skipped 'test_ci_windows' because the config is the same (dry run)
Skipped 'ci_packaging_windows' because the config is the same (dry run)
Skipped 'packaging_windows' because the config is the same (dry run)
Skipped 'packaging_windows_debug' because the config is the same (dry run)
Skipped 'nightly_win_deb' because the config is the same (dry run)
Skipped 'nightly_win_rel' because the config is the same (dry run)
Skipped 'nightly_win_rep' because the config is the same (dry run)
Skipped 'nightly_win_xfail' because the config is the same (dry run)
Skipped 'ci_windows-metal' because the config is the same (dry run)
Skipped 'test_ci_windows-metal' because the config is the same (dry run)
Skipped 'ci_launcher' because the config is the same (dry run)

Test RHEL build: Build Status

@cottsay cottsay requested a review from clalancette April 13, 2021 22:04
@cottsay cottsay self-assigned this Apr 13, 2021
Copy link
Contributor

@clalancette clalancette left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm actually wondering if instead of doing these regular expression substitutions, we instead just have a different string for test_args_default for RHEL. I think it would be a lot more readable for anyone else trying to follow along what we are doing here.

Thoughts?

@cottsay
Copy link
Member Author

cottsay commented Apr 27, 2021

we instead just have a different string for test_args_default for RHEL

That would eliminate the first regex, but the two subsequent ones are still required. The string replacements fail if the arg isn't verbatim --ctest-args -LE xfail.

@cottsay cottsay requested a review from clalancette April 28, 2021 17:59
@cottsay cottsay merged commit c0973c6 into master May 5, 2021
@delete-merged-branch delete-merged-branch bot deleted the cottsay/ctest_labels branch May 5, 2021 21:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants