#3201

Reject empty tag filters as invalid test specifications

Openvzer200wants to merge intofrom

Description

Passing [] to SelfTest currently runs all default tests because the empty tag is silently discarded. Reject it as an invalid test specification (exit code 5), including negated filters, combined filters, and empty tags expanded from aliases.

Report the original argument once. Track whether the current tag contains any characters so that text left by an earlier argument cannot hide an empty tag. Add parser regressions, a CLI error-handling test, and a versioned documentation note.

Validation on Windows with LLVM-MinGW:

  • 224 parser assertions and all 83 basic CTest tests pass, including approvals. A separate review reran all 83 tests and compared 261 CLI argument vectors with the original build.
  • An eight-test fixture checked 1,230 argument combinations: 411 empty-tag combinations are rejected and 819 other combinations retain their original selections and exit codes.
  • The all-tests build succeeds; 143 of 145 CTest tests pass. The same two failures reproduce on unchanged upstream: ExperimentalRedirect's unused private field warning and the JUnit crash reporter's missing closing element. Builds use a local -Wno-error=pointer-bool-conversion flag for an existing Clang 23 warning; no compiler settings are changed in this PR.

Prepared with Codex and independently reviewed by a separate agent before submission.

GitHub Issues

Addresses the CLI follow-up in #2367. The original JUnit assertion crash is outside this change.

Activity

3
codecov[bot]1mo ago

Codecov Report

:white_check_mark: All modified and coverable lines are covered by tests. :white_check_mark: Project coverage is 91.18%. Comparing base (897d804) to head (9c879c5). :warning: Report is 15 commits behind head on devel.

Additional details and impacted files
@@            Coverage Diff             @@
##            devel    #3201      +/-   ##
==========================================
+ Coverage   91.17%   91.18%   +0.01%     
==========================================
  Files         206      206              
  Lines        9031     9039       +8     
==========================================
+ Hits         8234     8242       +8     
  Misses        797      797              
:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
horenmarreviewed1mo ago
horenmar1mo ago

Needs few small changes