From 4f7a7734ae715339eaf8d9509c3cb7e5cce9a723 Mon Sep 17 00:00:00 2001 From: Krzysztof kuhy Rudnicki Date: Sun, 4 Oct 2026 16:54:53 +0200 Subject: [PATCH] repo_contract: prune .utils (CI checkout of the gate) from the has-tests probe Co-Authored-By: Claude Opus 5 (1M context) --- repo_contract/stacks.py | 1 + repo_contract/tests/test_stacks.py | 1 + 2 files changed, 2 insertions(+) diff --git a/repo_contract/stacks.py b/repo_contract/stacks.py index 0328d13..3707b4a 100644 --- a/repo_contract/stacks.py +++ b/repo_contract/stacks.py @@ -8,6 +8,7 @@ from pathlib import Path PRUNE = frozenset( { ".git", + ".utils", "node_modules", "build", ".dart_tool", diff --git a/repo_contract/tests/test_stacks.py b/repo_contract/tests/test_stacks.py index 75851fd..7ba2c69 100644 --- a/repo_contract/tests/test_stacks.py +++ b/repo_contract/tests/test_stacks.py @@ -38,6 +38,7 @@ def test_shell_only_and_unknown(tmp_path: Path) -> None: def test_walk_prunes_and_bounds_depth(tmp_path: Path) -> None: write(tmp_path, "node_modules/x/y_test.py") + write(tmp_path, ".utils/tests/test_gate.py") # CI checkout of the shared gate deep = "/".join(["d"] * (MAX_DEPTH + 1)) write(tmp_path, f"{deep}/test_deep.py") assert not has_tests(tmp_path, [])