PR #1014 follow-ups: lock in the star-import-shim false-positive coverage nf-f58 ← Beads

open priority 2 task unassigned

Twinned from https://github.com/cfsh/ninefold/issues/1022 by tools/beads/import_github.py's reconcile pass.

Suggestions from ninefold-reviewer's review of #1014

  1. presubmit.py's _loaded_test_modules() (added in #1014) deliberately diffs sys.modules instead of using type(test).__module__, specifically to avoid misattributing tools/tests/test_design_docs_operationalize.py and test_github_live.py (both from other.module import * re-export shims) as silently dropped by unittest discover. The function's own docstring (presubmit.py:167-175) names this exact false positive as something "measured wrong on this tree" during development — but the fix is validated only by a one-off live run against the real tree, not by a fixture in DiscoveryReconciliationTest (tools/tests/test_presubmit.py:148). None of its five cases include a star-import shim, so a future regression here (e.g. someone "simplifying" back to type(test).__module__) would pass the suite cleanly. Add a fixture: a _test.py that from sibling_test import *s another file's TestCase subclasses, asserting discovery_reconciliation() still reports it as loaded.

Dependencies

None.

Comments

No comments.

Add a comment