diff --git a/.github/workflows/shared-gates-tests.yml b/.github/workflows/shared-gates-tests.yml index 3380f86..d1b9bce 100644 --- a/.github/workflows/shared-gates-tests.yml +++ b/.github/workflows/shared-gates-tests.yml @@ -56,6 +56,15 @@ jobs: --cov-report=term-missing \ --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 run: | PYTHONPATH=. python -m pytest coverage_gaps/tests -q \ diff --git a/CLAUDE.md b/CLAUDE.md index 502c186..55aa400 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -10,8 +10,8 @@ overwrite it with `repo_contract/templates/check_repo_contract.shim.sh`. ## Commands - 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` -- lint: `ruff check 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` +- lint: `ruff check agent_ready coverage_gaps repo_contract` +- 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` diff --git a/scripts/test_changed.sh b/scripts/test_changed.sh index 1b6346f..b61f6aa 100755 --- a/scripts/test_changed.sh +++ b/scripts/test_changed.sh @@ -16,7 +16,7 @@ while IFS= read -r f; do [[ -n "$f" && -e "$f" ]] && CHANGED+=("$f") 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=() unmapped=0 for f in "${CHANGED[@]}"; do