Skip to content

Commit 3c42e06

Browse files
tbitcsoz-agent
andcommitted
fix(codeql): wire _FLEX_TEST into _TEST_ID_PATTERN — resolves unused-variable alert #132
_TEST_ID_PATTERN was duplicating the TEST- regex inline instead of referencing the module-level _FLEX_TEST constant, leaving _FLEX_TEST unused. Co-Authored-By: Oz <oz-agent@warp.dev>
1 parent 89b97cb commit 3c42e06

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/specsmith/requirements.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
r"(?:Covers|\*\*Requirement(?:\s+ID)?:?\*\*|Requirement(?:\s+ID)?):?\s*"
2121
r"(" + _FLEX_REQ + r"(?:\s*,\s*" + _FLEX_REQ + r")*)"
2222
)
23-
_TEST_ID_PATTERN = re.compile(r"\b(TEST-(?:[A-Z][A-Z0-9_]*-)?\d+[a-z]*)\b")
23+
_TEST_ID_PATTERN = re.compile(r"\b(" + _FLEX_TEST + r")\b")
2424

2525
# Heading detectors for REQUIREMENTS.md (two styles supported):
2626
# Style A: ## REQ-001 or ## REQ-CLI-001

0 commit comments

Comments
 (0)