Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-98865

Unittests for coverage should be running "with_debug" but get filtered out

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Build
    • Fully Compatible
    • ALL
    • 2025-01-21

      The following reproduces what occurs in CI, for a single test:

      bazel coverage //src/mongo/platform:visibility1_test_with_debug \
        --test_output=all \
        --combined_report=lcov \
        --compiler_type=gcc \
        --config=local \
        --compiler_type=gcc \
        --linkstatic=False \
        --test_output=all \
        --combined_report=lcov \
        --test_timeout=600 \
        --verbose_failures \
        --copt=-Wno-mismatched-new-delete \
        --test_tag_filters=mongo_unittest,-intermediate_target,-code_coverage_quarantine
      

      But the test itself is filtered out because the "with_debug" target is tagged with "intermediate_target". Running the non-debug target runs fine, but then doesn't have the right instrumentation to get the coverage results. So running "..." sort of targets never produce any coverage metrics.

            Assignee:
            steve.mcclure@mongodb.com Steve McClure
            Reporter:
            steve.mcclure@mongodb.com Steve McClure
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: