Problem
The new release detection (from #2) correctly scans for unwired symbols at tag time, but flags test classes and test functions as "dead code." Test functions like test_rebase_branch_success and test classes like TestParseCriteria are invoked by pytest, not by application code — they're not dead.
This inflates the count significantly: v3.3.0 shows 169 "unwired symbols" but most are test functions. The actual dead application code is much smaller.
Fix
Exclude symbols matching these patterns from the dead code count:
- Functions starting with
test_
- Classes starting with
Test
- Functions named
pytest_* (pytest hooks)
- Files under
tests/ directory
- Fixtures (
@pytest.fixture)
Report test symbols separately if at all:
v3.3.0: 12 unwired application symbols, 157 new test symbols (excluded)
Evidence
From today's scan, v3.3.0 flagged: TestParseCriteria, test_bullet_items, test_skips_short_lines, TestHeuristicCompile, test_test_keyword_shell_check — all test code, all correctly invoked by pytest.
Problem
The new release detection (from #2) correctly scans for unwired symbols at tag time, but flags test classes and test functions as "dead code." Test functions like
test_rebase_branch_successand test classes likeTestParseCriteriaare invoked by pytest, not by application code — they're not dead.This inflates the count significantly: v3.3.0 shows 169 "unwired symbols" but most are test functions. The actual dead application code is much smaller.
Fix
Exclude symbols matching these patterns from the dead code count:
test_Testpytest_*(pytest hooks)tests/directory@pytest.fixture)Report test symbols separately if at all:
Evidence
From today's scan, v3.3.0 flagged:
TestParseCriteria,test_bullet_items,test_skips_short_lines,TestHeuristicCompile,test_test_keyword_shell_check— all test code, all correctly invoked by pytest.