mirror of
https://github.com/kuhyx/utils.git
synced 2026-11-10 19:07:17 +01:00
agent_ready: wire into CLAUDE.md commands, shared-gate CI and test_changed
The checker shipped with 100% branch coverage but nothing ran it: add it to the CLAUDE.md test/lint/coverage commands, the shared-gates-tests workflow (--cov-fail-under=100, same shape as repo_contract/coverage_gaps) and the test_changed.sh fallback gate list. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01NBScELfMUiieK9ManFbS3Y
This commit is contained in:
parent
a0fb279b1b
commit
abc3ada6c3
9
.github/workflows/shared-gates-tests.yml
vendored
9
.github/workflows/shared-gates-tests.yml
vendored
@ -56,6 +56,15 @@ jobs:
|
|||||||
--cov-report=term-missing \
|
--cov-report=term-missing \
|
||||||
--cov-fail-under=100
|
--cov-fail-under=100
|
||||||
|
|
||||||
|
# Every web repo's pre-commit and CI run this checker against its dist/,
|
||||||
|
# so a false green here ships an un-agent-ready site fleet-wide.
|
||||||
|
- name: agent_ready — 100% branch coverage on the checker
|
||||||
|
run: |
|
||||||
|
PYTHONPATH=. python -m pytest agent_ready/tests -q \
|
||||||
|
--cov=agent_ready --cov-branch \
|
||||||
|
--cov-report=term-missing \
|
||||||
|
--cov-fail-under=100
|
||||||
|
|
||||||
- name: coverage_gaps — 100% branch coverage on the lister
|
- name: coverage_gaps — 100% branch coverage on the lister
|
||||||
run: |
|
run: |
|
||||||
PYTHONPATH=. python -m pytest coverage_gaps/tests -q \
|
PYTHONPATH=. python -m pytest coverage_gaps/tests -q \
|
||||||
|
|||||||
@ -10,8 +10,8 @@ overwrite it with `repo_contract/templates/check_repo_contract.shim.sh`.
|
|||||||
## Commands
|
## Commands
|
||||||
|
|
||||||
- run: n/a: collection of gates and libraries, no single entry point
|
- run: n/a: collection of gates and libraries, no single entry point
|
||||||
- test: `PYTHONPATH=. python -m pytest -q coverage_gaps/tests dep_freshness/tests file_length/tests home_paths/tests md_naming/tests repo_contract/tests scripts/tests`
|
- test: `PYTHONPATH=. python -m pytest -q agent_ready/tests coverage_gaps/tests dep_freshness/tests file_length/tests home_paths/tests md_naming/tests repo_contract/tests scripts/tests`
|
||||||
- test-changed: `scripts/test_changed.sh`
|
- test-changed: `scripts/test_changed.sh`
|
||||||
- lint: `ruff check coverage_gaps repo_contract`
|
- lint: `ruff check agent_ready coverage_gaps repo_contract`
|
||||||
- coverage: `PYTHONPATH=. python -m pytest -q repo_contract/tests --cov=repo_contract --cov-branch --cov-report=xml --cov-fail-under=100`
|
- coverage: `PYTHONPATH=. python -m pytest -q agent_ready/tests repo_contract/tests --cov=agent_ready --cov=repo_contract --cov-branch --cov-report=xml --cov-fail-under=100`
|
||||||
- coverage-gaps: `coverage-gaps coverage.xml`
|
- coverage-gaps: `coverage-gaps coverage.xml`
|
||||||
|
|||||||
@ -16,7 +16,7 @@ while IFS= read -r f; do
|
|||||||
[[ -n "$f" && -e "$f" ]] && CHANGED+=("$f")
|
[[ -n "$f" && -e "$f" ]] && CHANGED+=("$f")
|
||||||
done < <({ git diff --name-only HEAD 2>/dev/null || true; git ls-files --others --exclude-standard; } | sort -u)
|
done < <({ git diff --name-only HEAD 2>/dev/null || true; git ls-files --others --exclude-standard; } | sort -u)
|
||||||
|
|
||||||
readonly GATES=(coverage_gaps dep_freshness file_length home_paths md_naming repo_contract)
|
readonly GATES=(agent_ready coverage_gaps dep_freshness file_length home_paths md_naming repo_contract)
|
||||||
dirs=()
|
dirs=()
|
||||||
unmapped=0
|
unmapped=0
|
||||||
for f in "${CHANGED[@]}"; do
|
for f in "${CHANGED[@]}"; do
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user