bigpowers 2.86.6 → 2.86.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.agents/skills/guard-git/SKILL.md +8 -8
- package/.agents/skills/kickoff-branch/SKILL.md +1 -1
- package/.agents/skills/migrate-spec/SKILL.md +52 -6
- package/.agents/skills/plan-work/SKILL.md +17 -5
- package/.agents/skills/publish-package/SKILL.md +15 -5
- package/.agents/skills/release-branch/SKILL.md +12 -8
- package/.agents/skills/seed-conventions/SKILL.md +20 -10
- package/.agents/skills/smoke-test/SKILL.md +9 -5
- package/.agents/skills/validate-contracts/SKILL.md +15 -6
- package/.agents/skills/wire-ci/SKILL.md +12 -5
- package/.agents/skills/write-document/SKILL.md +30 -4
- package/.cline/skills/guard-git/SKILL.md +8 -8
- package/.cline/skills/kickoff-branch/SKILL.md +1 -1
- package/.cline/skills/migrate-spec/SKILL.md +52 -6
- package/.cline/skills/plan-work/SKILL.md +17 -5
- package/.cline/skills/publish-package/SKILL.md +15 -5
- package/.cline/skills/release-branch/SKILL.md +12 -8
- package/.cline/skills/seed-conventions/SKILL.md +20 -10
- package/.cline/skills/smoke-test/SKILL.md +9 -5
- package/.cline/skills/validate-contracts/SKILL.md +15 -6
- package/.cline/skills/wire-ci/SKILL.md +12 -5
- package/.cline/skills/write-document/SKILL.md +30 -4
- package/.codebuddy/skills/guard-git/SKILL.md +8 -8
- package/.codebuddy/skills/kickoff-branch/SKILL.md +1 -1
- package/.codebuddy/skills/migrate-spec/SKILL.md +52 -6
- package/.codebuddy/skills/plan-work/SKILL.md +17 -5
- package/.codebuddy/skills/publish-package/SKILL.md +15 -5
- package/.codebuddy/skills/release-branch/SKILL.md +12 -8
- package/.codebuddy/skills/seed-conventions/SKILL.md +20 -10
- package/.codebuddy/skills/smoke-test/SKILL.md +9 -5
- package/.codebuddy/skills/validate-contracts/SKILL.md +15 -6
- package/.codebuddy/skills/wire-ci/SKILL.md +12 -5
- package/.codebuddy/skills/write-document/SKILL.md +30 -4
- package/.codex/skills/guard-git/SKILL.md +8 -8
- package/.codex/skills/kickoff-branch/SKILL.md +1 -1
- package/.codex/skills/migrate-spec/SKILL.md +52 -6
- package/.codex/skills/plan-work/SKILL.md +17 -5
- package/.codex/skills/publish-package/SKILL.md +15 -5
- package/.codex/skills/release-branch/SKILL.md +12 -8
- package/.codex/skills/seed-conventions/SKILL.md +20 -10
- package/.codex/skills/smoke-test/SKILL.md +9 -5
- package/.codex/skills/validate-contracts/SKILL.md +15 -6
- package/.codex/skills/wire-ci/SKILL.md +12 -5
- package/.codex/skills/write-document/SKILL.md +30 -4
- package/.copilot/skills/guard-git/SKILL.md +8 -8
- package/.copilot/skills/kickoff-branch/SKILL.md +1 -1
- package/.copilot/skills/migrate-spec/SKILL.md +52 -6
- package/.copilot/skills/plan-work/SKILL.md +17 -5
- package/.copilot/skills/publish-package/SKILL.md +15 -5
- package/.copilot/skills/release-branch/SKILL.md +12 -8
- package/.copilot/skills/seed-conventions/SKILL.md +20 -10
- package/.copilot/skills/smoke-test/SKILL.md +9 -5
- package/.copilot/skills/validate-contracts/SKILL.md +15 -6
- package/.copilot/skills/wire-ci/SKILL.md +12 -5
- package/.copilot/skills/write-document/SKILL.md +30 -4
- package/.hermes/skills/guard-git/SKILL.md +8 -8
- package/.hermes/skills/kickoff-branch/SKILL.md +1 -1
- package/.hermes/skills/migrate-spec/SKILL.md +52 -6
- package/.hermes/skills/plan-work/SKILL.md +17 -5
- package/.hermes/skills/publish-package/SKILL.md +15 -5
- package/.hermes/skills/release-branch/SKILL.md +12 -8
- package/.hermes/skills/seed-conventions/SKILL.md +20 -10
- package/.hermes/skills/smoke-test/SKILL.md +9 -5
- package/.hermes/skills/validate-contracts/SKILL.md +15 -6
- package/.hermes/skills/wire-ci/SKILL.md +12 -5
- package/.hermes/skills/write-document/SKILL.md +30 -4
- package/.kilocode/rules/guard-git.md +8 -8
- package/.kilocode/rules/kickoff-branch.md +1 -1
- package/.kilocode/rules/migrate-spec.md +52 -6
- package/.kilocode/rules/plan-work.md +17 -5
- package/.kilocode/rules/publish-package.md +15 -5
- package/.kilocode/rules/release-branch.md +12 -8
- package/.kilocode/rules/seed-conventions.md +20 -10
- package/.kilocode/rules/smoke-test.md +9 -5
- package/.kilocode/rules/validate-contracts.md +15 -6
- package/.kilocode/rules/wire-ci.md +12 -5
- package/.kilocode/rules/write-document.md +30 -4
- package/.mimocode/skills/guard-git/SKILL.md +8 -8
- package/.mimocode/skills/kickoff-branch/SKILL.md +1 -1
- package/.mimocode/skills/migrate-spec/SKILL.md +52 -6
- package/.mimocode/skills/plan-work/SKILL.md +17 -5
- package/.mimocode/skills/publish-package/SKILL.md +15 -5
- package/.mimocode/skills/release-branch/SKILL.md +12 -8
- package/.mimocode/skills/seed-conventions/SKILL.md +20 -10
- package/.mimocode/skills/smoke-test/SKILL.md +9 -5
- package/.mimocode/skills/validate-contracts/SKILL.md +15 -6
- package/.mimocode/skills/wire-ci/SKILL.md +12 -5
- package/.mimocode/skills/write-document/SKILL.md +30 -4
- package/.opencode/skills/guard-git/SKILL.md +8 -8
- package/.opencode/skills/kickoff-branch/SKILL.md +1 -1
- package/.opencode/skills/migrate-spec/SKILL.md +52 -6
- package/.opencode/skills/plan-work/SKILL.md +17 -5
- package/.opencode/skills/publish-package/SKILL.md +15 -5
- package/.opencode/skills/release-branch/SKILL.md +12 -8
- package/.opencode/skills/seed-conventions/SKILL.md +20 -10
- package/.opencode/skills/smoke-test/SKILL.md +9 -5
- package/.opencode/skills/validate-contracts/SKILL.md +15 -6
- package/.opencode/skills/wire-ci/SKILL.md +12 -5
- package/.opencode/skills/write-document/SKILL.md +30 -4
- package/.pi/package.json +1 -1
- package/.pi/prompts/guard-git.md +8 -8
- package/.pi/prompts/kickoff-branch.md +1 -1
- package/.pi/prompts/migrate-spec.md +52 -6
- package/.pi/prompts/plan-work.md +17 -5
- package/.pi/prompts/publish-package.md +15 -5
- package/.pi/prompts/release-branch.md +12 -8
- package/.pi/prompts/seed-conventions.md +20 -10
- package/.pi/prompts/smoke-test.md +9 -5
- package/.pi/prompts/validate-contracts.md +15 -6
- package/.pi/prompts/wire-ci.md +12 -5
- package/.pi/prompts/write-document.md +30 -4
- package/.pi/skills/guard-git/SKILL.md +8 -8
- package/.pi/skills/kickoff-branch/SKILL.md +1 -1
- package/.pi/skills/migrate-spec/SKILL.md +52 -6
- package/.pi/skills/plan-work/SKILL.md +17 -5
- package/.pi/skills/publish-package/SKILL.md +15 -5
- package/.pi/skills/release-branch/SKILL.md +12 -8
- package/.pi/skills/seed-conventions/SKILL.md +20 -10
- package/.pi/skills/smoke-test/SKILL.md +9 -5
- package/.pi/skills/validate-contracts/SKILL.md +15 -6
- package/.pi/skills/wire-ci/SKILL.md +12 -5
- package/.pi/skills/write-document/SKILL.md +30 -4
- package/.qwen/skills/guard-git/SKILL.md +8 -8
- package/.qwen/skills/kickoff-branch/SKILL.md +1 -1
- package/.qwen/skills/migrate-spec/SKILL.md +52 -6
- package/.qwen/skills/plan-work/SKILL.md +17 -5
- package/.qwen/skills/publish-package/SKILL.md +15 -5
- package/.qwen/skills/release-branch/SKILL.md +12 -8
- package/.qwen/skills/seed-conventions/SKILL.md +20 -10
- package/.qwen/skills/smoke-test/SKILL.md +9 -5
- package/.qwen/skills/validate-contracts/SKILL.md +15 -6
- package/.qwen/skills/wire-ci/SKILL.md +12 -5
- package/.qwen/skills/write-document/SKILL.md +30 -4
- package/.trae/skills/guard-git/SKILL.md +8 -8
- package/.trae/skills/kickoff-branch/SKILL.md +1 -1
- package/.trae/skills/migrate-spec/SKILL.md +52 -6
- package/.trae/skills/plan-work/SKILL.md +17 -5
- package/.trae/skills/publish-package/SKILL.md +15 -5
- package/.trae/skills/release-branch/SKILL.md +12 -8
- package/.trae/skills/seed-conventions/SKILL.md +20 -10
- package/.trae/skills/smoke-test/SKILL.md +9 -5
- package/.trae/skills/validate-contracts/SKILL.md +15 -6
- package/.trae/skills/wire-ci/SKILL.md +12 -5
- package/.trae/skills/write-document/SKILL.md +30 -4
- package/.windsurf/rules/guard-git.md +8 -8
- package/.windsurf/rules/kickoff-branch.md +1 -1
- package/.windsurf/rules/migrate-spec.md +52 -6
- package/.windsurf/rules/plan-work.md +17 -5
- package/.windsurf/rules/publish-package.md +15 -5
- package/.windsurf/rules/release-branch.md +12 -8
- package/.windsurf/rules/seed-conventions.md +20 -10
- package/.windsurf/rules/smoke-test.md +9 -5
- package/.windsurf/rules/validate-contracts.md +15 -6
- package/.windsurf/rules/wire-ci.md +12 -5
- package/.windsurf/rules/write-document.md +30 -4
- package/.zcode/skills/guard-git/SKILL.md +8 -8
- package/.zcode/skills/kickoff-branch/SKILL.md +1 -1
- package/.zcode/skills/migrate-spec/SKILL.md +52 -6
- package/.zcode/skills/plan-work/SKILL.md +17 -5
- package/.zcode/skills/publish-package/SKILL.md +15 -5
- package/.zcode/skills/release-branch/SKILL.md +12 -8
- package/.zcode/skills/seed-conventions/SKILL.md +20 -10
- package/.zcode/skills/smoke-test/SKILL.md +9 -5
- package/.zcode/skills/validate-contracts/SKILL.md +15 -6
- package/.zcode/skills/wire-ci/SKILL.md +12 -5
- package/.zcode/skills/write-document/SKILL.md +30 -4
- package/CHANGELOG.md +7 -0
- package/CONVENTIONS.md +2 -0
- package/package.json +1 -1
- package/scripts/generate-context-bundle.sh +6 -0
- package/scripts/generate-reference-nav.sh +89 -0
- package/scripts/generate-viz-graph.sh +4 -0
- package/scripts/golden-g13-script-orphans.sh +167 -0
- package/scripts/golden-g15-compliance-runner-selftest.sh +126 -0
- package/scripts/golden-g16-spec-version-gap.sh +72 -0
- package/scripts/lib/__pycache__/link_utils.cpython-312.pyc +0 -0
- package/scripts/lib/__pycache__/srp_engine_links.cpython-312.pyc +0 -0
- package/scripts/lib/audit-compliance-report.sh +32 -7
- package/scripts/lib/audit-compliance-runner.sh +14 -1
- package/scripts/lib/golden-suite-gates.sh +23 -7
- package/scripts/lib/test-assertions.sh +4 -0
- package/scripts/snapshot-catalog-baseline.sh +4 -0
- package/scripts/test-adapter-render.sh +19 -21
- package/scripts/test-completeness-critic-scope.sh +18 -19
- package/scripts/test-generate-epics-wiki-zero-stories.sh +12 -13
- package/scripts/test-golden-g11-worktree-venv.sh +16 -18
- package/scripts/test-install-distribute-only.sh +27 -26
- package/scripts/test-install-hub.sh +25 -23
- package/scripts/test-setup-no-pyyaml.sh +16 -17
- package/scripts/test-target-contracts.sh +15 -13
- package/scripts/test-tombstone-mechanism.sh +31 -33
- package/skills/guard-git/REFERENCE.md +8 -8
- package/skills/kickoff-branch/SKILL.md +1 -1
- package/skills/migrate-spec/REFERENCE.md +52 -6
- package/skills/plan-work/REFERENCE.md +17 -5
- package/skills/publish-package/REFERENCE.md +15 -5
- package/skills/release-branch/REFERENCE.md +12 -8
- package/skills/seed-conventions/REFERENCE.md +20 -10
- package/skills/smoke-test/REFERENCE.md +9 -5
- package/skills/validate-contracts/REFERENCE.md +15 -6
- package/skills/wire-ci/REFERENCE.md +12 -5
- package/skills/write-document/REFERENCE.md +30 -4
- package/skills-lock.json +1 -1
- package/scripts/add-model-frontmatter.sh +0 -32
- package/scripts/golden-g13-test-orphans.sh +0 -70
- package/scripts/install-cursor-skills-local.sh +0 -15
- package/scripts/install-cursor-skills.sh +0 -24
- package/scripts/project-survey.sh +0 -63
|
@@ -84,13 +84,26 @@ audit_run_file() {
|
|
|
84
84
|
TOTAL_PASS=0
|
|
85
85
|
TOTAL_FAIL=0
|
|
86
86
|
|
|
87
|
-
|
|
87
|
+
# `|| [[ -n "$line" ]]` is required: read returns non-zero on a final line
|
|
88
|
+
# with no trailing newline, so without this a feature file not ending in \n
|
|
89
|
+
# silently drops its last step — confirmed on karpathy.feature, whose last
|
|
90
|
+
# line ("And I should push back on unnecessary complexity") never appeared
|
|
91
|
+
# in [STEP] output at all.
|
|
92
|
+
while IFS= read -r line || [[ -n "$line" ]]; do
|
|
88
93
|
line=$(echo "$line" | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')
|
|
89
94
|
|
|
90
95
|
if [[ "$line" =~ ^Feature: ]]; then
|
|
91
96
|
CURRENT_FEATURE="${line#Feature: }"
|
|
92
97
|
echo "FEATURE: $CURRENT_FEATURE"
|
|
93
98
|
echo "## Feature: $CURRENT_FEATURE" >> "$REPORT_FILE"
|
|
99
|
+
elif [[ "$line" =~ ^Background: ]]; then
|
|
100
|
+
# A Background's Given/And lines must execute the same as a Scenario's —
|
|
101
|
+
# without this branch IN_SCENARIO never goes true here, so every step
|
|
102
|
+
# under Background is silently skipped (not FAILed, not counted at all).
|
|
103
|
+
# Runs once per file, matching how every other line here executes once
|
|
104
|
+
# as encountered — not true per-scenario Gherkin re-execution semantics.
|
|
105
|
+
IN_SCENARIO=true
|
|
106
|
+
CURRENT_SCENARIO="Background"
|
|
94
107
|
elif [[ "$line" =~ ^Scenario: ]]; then
|
|
95
108
|
CURRENT_SCENARIO="${line#Scenario: }"
|
|
96
109
|
if [[ -n "$SCENARIO_FILTER" && "$CURRENT_SCENARIO" != "$SCENARIO_FILTER" ]]; then
|
|
@@ -19,20 +19,36 @@ GOLDEN_GATES=(
|
|
|
19
19
|
# first so a vacuous gate is caught before its verdict is trusted.
|
|
20
20
|
"g12-status-selftest:bash scripts/golden-g12-status-consistency.sh --self-test:false"
|
|
21
21
|
"g12-status-consistency:bash scripts/golden-g12-status-consistency.sh:false"
|
|
22
|
-
#
|
|
23
|
-
#
|
|
24
|
-
#
|
|
25
|
-
#
|
|
26
|
-
#
|
|
27
|
-
|
|
28
|
-
"
|
|
22
|
+
# audit-compliance-runner.sh silently dropped a Background: step and a
|
|
23
|
+
# feature file's last line when it had no trailing newline — a step exists,
|
|
24
|
+
# is correct, and never runs is exactly this session's recurring defect
|
|
25
|
+
# class. Fixture-based regression guard for both, plus a check that a fix
|
|
26
|
+
# to "make steps execute" doesn't also make a genuinely failing step report
|
|
27
|
+
# as PASS.
|
|
28
|
+
"g15-compliance-runner-selftest:bash scripts/golden-g15-compliance-runner-selftest.sh --self-test:false"
|
|
29
|
+
"g15-compliance-runner:bash scripts/golden-g15-compliance-runner-selftest.sh:false"
|
|
30
|
+
# Writing a script must be enough to make it run: G-13 fails if any
|
|
31
|
+
# scripts/*.sh is absent, unreferenced, and untagged bp-manual-utility.
|
|
32
|
+
# Broadened from scripts/test-*.sh only after a catalog-wide review found 9
|
|
33
|
+
# more orphans among non-test scripts; renamed to match (golden-g13-test-
|
|
34
|
+
# orphans.sh -> golden-g13-script-orphans.sh).
|
|
35
|
+
"g13-script-orphans-selftest:bash scripts/golden-g13-script-orphans.sh --self-test:false"
|
|
36
|
+
"g13-script-orphans:bash scripts/golden-g13-script-orphans.sh:false"
|
|
29
37
|
# An adapter that defines render_skill() must be dispatched by targets.yaml,
|
|
30
38
|
# or sync renders nothing for it while its install still claims success.
|
|
31
39
|
# docs/WORKFLOWS.md is generated from specs/workflows/*.yaml; a diagram nothing
|
|
32
40
|
# regenerates is a diagram that lies (see specs/archive/assets/README.md).
|
|
33
41
|
"workflow-diagrams-fresh:bash scripts/generate-workflow-diagrams.sh --check:false"
|
|
42
|
+
# REFERENCE.md nav tables are line-number indexes; hand-maintained they drift
|
|
43
|
+
# the moment a section grows (all 10 were stale when this gate was added).
|
|
44
|
+
"reference-nav-fresh:bash scripts/generate-reference-nav.sh --check:false"
|
|
34
45
|
"g14-adapter-dispatch-selftest:bash scripts/golden-g14-adapter-dispatch.sh --self-test:false"
|
|
35
46
|
"g14-adapter-dispatch:bash scripts/golden-g14-adapter-dispatch.sh:false"
|
|
47
|
+
# check-spec-version-gap.sh is a fully-formed SoT-drift detector for
|
|
48
|
+
# consuming projects but had no gate of its own (G-13 orphan). Self-checking
|
|
49
|
+
# bigpowers' own repo against its own package.json is the natural gate.
|
|
50
|
+
"g16-spec-version-gap-selftest:bash scripts/golden-g16-spec-version-gap.sh --self-test:false"
|
|
51
|
+
"g16-spec-version-gap:bash scripts/golden-g16-spec-version-gap.sh:false"
|
|
36
52
|
"target-contracts:bash scripts/test-target-contracts.sh:false"
|
|
37
53
|
# Registry-driven replacements for the 25 hand-written per-target scripts.
|
|
38
54
|
"install-hub:bash scripts/test-install-hub.sh:false"
|
|
@@ -19,3 +19,7 @@ ta_cleanup() {
|
|
|
19
19
|
ta_pass() { echo " PASS $1"; TA_PASS=$((TA_PASS + 1)); }
|
|
20
20
|
|
|
21
21
|
ta_fail() { echo " FAIL $1"; TA_FAIL=$((TA_FAIL + 1)); }
|
|
22
|
+
|
|
23
|
+
# Strip ANSI color codes — used by scripts that grep the colored output of a
|
|
24
|
+
# gate/skill they're testing, where the escape codes would break the match.
|
|
25
|
+
ta_strip_ansi() { sed -E 's/\x1b\[[0-9;]*m//g'; }
|
|
@@ -2,6 +2,10 @@
|
|
|
2
2
|
# story: e54s01
|
|
3
3
|
# snapshot-catalog-baseline.sh — freeze the live skill catalog into a dated,
|
|
4
4
|
# immutable YAML baseline for e56's reclassification diff.
|
|
5
|
+
# bp-manual-utility: e56 (reclassify-catalog) is still `backlog` in
|
|
6
|
+
# execution-status.yaml — its sole consumer hasn't started, so there is
|
|
7
|
+
# nothing to wire this into yet. Promote to a gate when e56 kicks off; run
|
|
8
|
+
# manually until then: bash scripts/snapshot-catalog-baseline.sh
|
|
5
9
|
set -euo pipefail
|
|
6
10
|
|
|
7
11
|
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
@@ -18,17 +18,15 @@ source "$(dirname "${BASH_SOURCE[0]}")/lib/skill-common.sh"
|
|
|
18
18
|
resolve_repo_root
|
|
19
19
|
cd "$REPO_ROOT"
|
|
20
20
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
fail() { echo "FAIL: $1" >&2; FAIL=$((FAIL + 1)); }
|
|
25
|
-
|
|
26
|
-
TMP_ROOT=$(mktemp -d)
|
|
27
|
-
trap 'rm -rf "$TMP_ROOT"' EXIT
|
|
28
|
-
|
|
29
|
-
|
|
21
|
+
TA_PASS=0
|
|
22
|
+
TA_FAIL=0
|
|
23
|
+
TA_TMPDIR=""
|
|
30
24
|
|
|
25
|
+
source "$(dirname "${BASH_SOURCE[0]}")/lib/test-assertions.sh"
|
|
26
|
+
trap ta_cleanup EXIT
|
|
31
27
|
|
|
28
|
+
TA_TMPDIR=$(mktemp -d)
|
|
29
|
+
TMP_ROOT="$TA_TMPDIR"
|
|
32
30
|
echo "=== test-adapter-render.sh ==="
|
|
33
31
|
|
|
34
32
|
for adapter in scripts/adapters/*.sh; do
|
|
@@ -68,9 +66,9 @@ for adapter in scripts/adapters/*.sh; do
|
|
|
68
66
|
dest="$TMP_ROOT/$id"
|
|
69
67
|
mkdir -p "$dest"
|
|
70
68
|
if render_into "$dest" "test-skill" && [[ -n "$(find "$dest" -mindepth 1 2>/dev/null)" ]]; then
|
|
71
|
-
|
|
69
|
+
ta_pass "$id: render_skill writes an artifact from a SkillIR"
|
|
72
70
|
else
|
|
73
|
-
|
|
71
|
+
ta_fail "$id: render_skill produced no artifact (${outvars[*]})"
|
|
74
72
|
fi
|
|
75
73
|
|
|
76
74
|
# Path traversal must be refused — this is the security assertion the
|
|
@@ -82,14 +80,14 @@ for adapter in scripts/adapters/*.sh; do
|
|
|
82
80
|
sandbox="$TMP_ROOT/sandbox-$id"
|
|
83
81
|
mkdir -p "$sandbox/out"
|
|
84
82
|
if render_into "$sandbox/out" "../escape"; then
|
|
85
|
-
|
|
83
|
+
ta_fail "$id: accepted a path-traversal skill name"
|
|
86
84
|
else
|
|
87
|
-
|
|
85
|
+
ta_pass "$id: rejects path traversal in skill name"
|
|
88
86
|
fi
|
|
89
87
|
if [[ -e "$sandbox/escape" ]]; then
|
|
90
|
-
|
|
88
|
+
ta_fail "$id: path traversal escaped into $sandbox"
|
|
91
89
|
else
|
|
92
|
-
|
|
90
|
+
ta_pass "$id: traversal wrote nothing outside the destination"
|
|
93
91
|
fi
|
|
94
92
|
|
|
95
93
|
# Hook bundle + guard behaviour, only where the target ships hooks.
|
|
@@ -99,18 +97,18 @@ for adapter in scripts/adapters/*.sh; do
|
|
|
99
97
|
out="$(echo '{"tool_input":{"command":"git push --force origin main"}}' \
|
|
100
98
|
| bash "$guard" 2>/dev/null || true)"
|
|
101
99
|
grep -q 'block' <<<"$out" \
|
|
102
|
-
&&
|
|
103
|
-
||
|
|
100
|
+
&& ta_pass "$id: pre-tool guard blocks a dangerous git command" \
|
|
101
|
+
|| ta_fail "$id: pre-tool guard did not block git push --force"
|
|
104
102
|
fi
|
|
105
103
|
done
|
|
106
104
|
|
|
107
105
|
# The generic adapter-contract runner stays the source of truth for
|
|
108
106
|
# render_skill/wire_context wiring; assert it is green rather than restating it.
|
|
109
107
|
if bash scripts/test-adapters.sh 2>&1 | grep -q '0 failed'; then
|
|
110
|
-
|
|
108
|
+
ta_pass "test-adapters.sh reports 0 failed across the registry"
|
|
111
109
|
else
|
|
112
|
-
|
|
110
|
+
ta_fail "test-adapters.sh reported failures"
|
|
113
111
|
fi
|
|
114
112
|
|
|
115
|
-
echo "test-adapter-render: $
|
|
116
|
-
[[ "$
|
|
113
|
+
echo "test-adapter-render: $TA_PASS passed, $TA_FAIL failed"
|
|
114
|
+
[[ "$TA_FAIL" -eq 0 ]] || exit 1
|
|
@@ -15,9 +15,12 @@ RED='\033[0;31m'
|
|
|
15
15
|
GREEN='\033[0;32m'
|
|
16
16
|
NC='\033[0m'
|
|
17
17
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
TA_PASS=0
|
|
19
|
+
TA_FAIL=0
|
|
20
|
+
TA_TMPDIR=""
|
|
21
|
+
source "$REPO_ROOT/scripts/lib/test-assertions.sh"
|
|
22
|
+
# NOT `trap ta_cleanup EXIT` — this script's cleanup restores backed-up
|
|
23
|
+
# specs/state.yaml and specs/traceability-matrix.json, not a TA_TMPDIR.
|
|
21
24
|
|
|
22
25
|
STATE_FILE="specs/state.yaml"
|
|
23
26
|
MATRIX_FILE="specs/traceability-matrix.json"
|
|
@@ -26,12 +29,12 @@ MATRIX_BACKUP=$(mktemp)
|
|
|
26
29
|
cp "$STATE_FILE" "$STATE_BACKUP"
|
|
27
30
|
cp "$MATRIX_FILE" "$MATRIX_BACKUP"
|
|
28
31
|
|
|
29
|
-
|
|
32
|
+
completeness_critic_test_cleanup() {
|
|
30
33
|
cp "$STATE_BACKUP" "$STATE_FILE"
|
|
31
34
|
cp "$MATRIX_BACKUP" "$MATRIX_FILE"
|
|
32
35
|
rm -f "$STATE_BACKUP" "$MATRIX_BACKUP"
|
|
33
36
|
}
|
|
34
|
-
trap
|
|
37
|
+
trap completeness_critic_test_cleanup EXIT
|
|
35
38
|
|
|
36
39
|
run_critic() {
|
|
37
40
|
bash scripts/lib/completeness-critic.sh 2>&1 || true
|
|
@@ -56,18 +59,18 @@ sed -i.bak '/^active_story:/d' "$STATE_FILE" && rm -f "${STATE_FILE}.bak"
|
|
|
56
59
|
write_matrix '[]'
|
|
57
60
|
output=$(run_critic)
|
|
58
61
|
if echo "$output" | grep -q "\[WARNING\].*no active_story set"; then
|
|
59
|
-
|
|
62
|
+
ta_pass "unset active_story produces an explicit WARNING"
|
|
60
63
|
else
|
|
61
|
-
|
|
64
|
+
ta_fail "unset active_story did not produce the expected WARNING"
|
|
62
65
|
fi
|
|
63
66
|
|
|
64
67
|
# --- Scenario: active_story set but absent from the matrix → WARNING ---
|
|
65
68
|
printf 'active_story: e99s99\n' >> "$STATE_FILE"
|
|
66
69
|
output=$(run_critic)
|
|
67
70
|
if echo "$output" | grep -q "\[WARNING\].*e99s99 not found"; then
|
|
68
|
-
|
|
71
|
+
ta_pass "unresolved active_story produces an explicit WARNING"
|
|
69
72
|
else
|
|
70
|
-
|
|
73
|
+
ta_fail "unresolved active_story did not produce the expected WARNING"
|
|
71
74
|
fi
|
|
72
75
|
sed -i.bak '/^active_story:/d' "$STATE_FILE" && rm -f "${STATE_FILE}.bak"
|
|
73
76
|
|
|
@@ -76,24 +79,20 @@ printf 'active_story: e00s01\n' >> "$STATE_FILE"
|
|
|
76
79
|
write_matrix '[]'
|
|
77
80
|
output=$(run_critic)
|
|
78
81
|
if echo "$output" | grep -q "\[BLOCKER\] active story e00s01 has zero explicit story-tag links"; then
|
|
79
|
-
|
|
82
|
+
ta_pass "active story with zero tags is correctly flagged as BLOCKER"
|
|
80
83
|
else
|
|
81
|
-
|
|
84
|
+
ta_fail "active story with zero tags was not flagged as BLOCKER"
|
|
82
85
|
fi
|
|
83
86
|
|
|
84
87
|
# --- Scenario: active story IS tagged → no BLOCKER, even though sibling e00s02 is untagged ---
|
|
85
88
|
write_matrix '[{"method": "explicit_tag", "file": "scripts/fixture.sh", "line": 1, "confidence": 1.0}]'
|
|
86
89
|
output=$(run_critic)
|
|
87
90
|
if echo "$output" | grep -q "\[BLOCKER\] active story e00s01"; then
|
|
88
|
-
|
|
91
|
+
ta_fail "tagged active story incorrectly flagged as BLOCKER"
|
|
89
92
|
else
|
|
90
|
-
|
|
93
|
+
ta_pass "tagged active story is not flagged, and untagged sibling e00s02 does not leak into the check"
|
|
91
94
|
fi
|
|
92
95
|
|
|
93
96
|
echo "---"
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
else
|
|
97
|
-
echo -e "${RED}test-completeness-critic-scope: $FAILURES failure(s)${NC}"
|
|
98
|
-
fi
|
|
99
|
-
exit "$FAILURES"
|
|
97
|
+
echo "test-completeness-critic-scope: $TA_PASS passed, $TA_FAIL failed"
|
|
98
|
+
exit "$TA_FAIL"
|
|
@@ -16,19 +16,22 @@ RED='\033[0;31m'
|
|
|
16
16
|
GREEN='\033[0;32m'
|
|
17
17
|
NC='\033[0m'
|
|
18
18
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
19
|
+
TA_PASS=0
|
|
20
|
+
TA_FAIL=0
|
|
21
|
+
TA_TMPDIR=""
|
|
22
|
+
source "$(dirname "${BASH_SOURCE[0]}")/lib/test-assertions.sh"
|
|
23
|
+
# NOT `trap ta_cleanup EXIT` — this script's cleanup removes a named fixture
|
|
24
|
+
# epic dir and its OKF bundle, not a TA_TMPDIR.
|
|
22
25
|
|
|
23
26
|
FIXTURE_ID="e00"
|
|
24
27
|
FIXTURE_DIR="specs/epics/e00-zero-story-fixture"
|
|
25
28
|
FIXTURE_BUNDLE="specs/epics-wiki/${FIXTURE_ID}.okf.md"
|
|
26
29
|
|
|
27
|
-
|
|
30
|
+
epics_wiki_test_cleanup() {
|
|
28
31
|
rm -rf "$FIXTURE_DIR"
|
|
29
32
|
rm -f "$FIXTURE_BUNDLE"
|
|
30
33
|
}
|
|
31
|
-
trap
|
|
34
|
+
trap epics_wiki_test_cleanup EXIT
|
|
32
35
|
|
|
33
36
|
mkdir -p "$FIXTURE_DIR"
|
|
34
37
|
cat > "${FIXTURE_DIR}/epic.yaml" <<'FIXTUREEOF'
|
|
@@ -50,15 +53,11 @@ FIXTUREEOF
|
|
|
50
53
|
bash scripts/generate-epics-wiki.sh > /dev/null
|
|
51
54
|
|
|
52
55
|
if [[ ! -f "$FIXTURE_BUNDLE" ]]; then
|
|
53
|
-
|
|
56
|
+
ta_pass "generate-epics-wiki.sh skips a zero-story epic (no bundle emitted)"
|
|
54
57
|
else
|
|
55
|
-
|
|
58
|
+
ta_fail "generate-epics-wiki.sh emitted a bundle for a zero-story epic: $FIXTURE_BUNDLE"
|
|
56
59
|
fi
|
|
57
60
|
|
|
58
61
|
echo "---"
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
else
|
|
62
|
-
echo -e "${RED}test-generate-epics-wiki-zero-stories: $FAILURES failure(s)${NC}"
|
|
63
|
-
fi
|
|
64
|
-
exit "$FAILURES"
|
|
62
|
+
echo "test-generate-epics-wiki-zero-stories: $TA_PASS passed, $TA_FAIL failed"
|
|
63
|
+
exit "$TA_FAIL"
|
|
@@ -15,10 +15,12 @@ RED='\033[0;31m'
|
|
|
15
15
|
GREEN='\033[0;32m'
|
|
16
16
|
NC='\033[0m'
|
|
17
17
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
18
|
+
TA_PASS=0
|
|
19
|
+
TA_FAIL=0
|
|
20
|
+
TA_TMPDIR=""
|
|
21
|
+
source "$REPO_ROOT/scripts/lib/test-assertions.sh"
|
|
22
|
+
# NOT `trap ta_cleanup EXIT` — this script's cleanup moves a real .venv aside
|
|
23
|
+
# and back, not a TA_TMPDIR.
|
|
22
24
|
|
|
23
25
|
VENV_MOVED=0
|
|
24
26
|
if [[ -e .venv ]]; then
|
|
@@ -26,38 +28,34 @@ if [[ -e .venv ]]; then
|
|
|
26
28
|
VENV_MOVED=1
|
|
27
29
|
fi
|
|
28
30
|
|
|
29
|
-
|
|
31
|
+
golden_g11_test_cleanup() {
|
|
30
32
|
rm -rf .venv
|
|
31
33
|
if [[ "$VENV_MOVED" -eq 1 ]]; then
|
|
32
34
|
mv .venv.test-golden-g11-backup .venv
|
|
33
35
|
fi
|
|
34
36
|
}
|
|
35
|
-
trap
|
|
37
|
+
trap golden_g11_test_cleanup EXIT
|
|
36
38
|
|
|
37
39
|
# --- Scenario: .venv absent (fresh worktree) → gate still PASSes ---
|
|
38
40
|
if [[ -e .venv ]]; then
|
|
39
|
-
|
|
41
|
+
ta_fail "test setup failed to remove .venv before running the gate"
|
|
40
42
|
else
|
|
41
|
-
output=$(bash scripts/golden-g11-gitignore-venv.sh 2>&1 |
|
|
43
|
+
output=$(bash scripts/golden-g11-gitignore-venv.sh 2>&1 | ta_strip_ansi) && exit_code=0 || exit_code=$?
|
|
42
44
|
if [[ "$exit_code" -eq 0 ]] && echo "$output" | grep -q "PASS git check-ignore .venv"; then
|
|
43
|
-
|
|
45
|
+
ta_pass "gate PASSes when .venv does not exist on disk"
|
|
44
46
|
else
|
|
45
|
-
|
|
47
|
+
ta_fail "gate did not PASS with .venv absent (exit=$exit_code)"
|
|
46
48
|
fi
|
|
47
49
|
|
|
48
50
|
# The gate must clean up the .venv it created for the check — a fresh
|
|
49
51
|
# worktree shouldn't be left with a stray directory after a gate run.
|
|
50
52
|
if [[ ! -e .venv ]]; then
|
|
51
|
-
|
|
53
|
+
ta_pass "gate removes the .venv it created for the check"
|
|
52
54
|
else
|
|
53
|
-
|
|
55
|
+
ta_fail "gate left a stray .venv behind after the check"
|
|
54
56
|
fi
|
|
55
57
|
fi
|
|
56
58
|
|
|
57
59
|
echo "---"
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
else
|
|
61
|
-
echo -e "${RED}test-golden-g11-worktree-venv: $FAILURES failure(s)${NC}"
|
|
62
|
-
fi
|
|
63
|
-
exit "$FAILURES"
|
|
60
|
+
echo "test-golden-g11-worktree-venv: $TA_PASS passed, $TA_FAIL failed"
|
|
61
|
+
exit "$TA_FAIL"
|
|
@@ -5,24 +5,25 @@
|
|
|
5
5
|
set -euo pipefail
|
|
6
6
|
|
|
7
7
|
REPO_ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
TA_PASS=0
|
|
9
|
+
TA_FAIL=0
|
|
10
|
+
TA_TMPDIR=""
|
|
10
11
|
|
|
11
|
-
|
|
12
|
-
|
|
12
|
+
source "$REPO_ROOT/scripts/lib/test-assertions.sh"
|
|
13
|
+
trap ta_cleanup EXIT
|
|
13
14
|
|
|
14
15
|
echo "=== test-install-distribute-only.sh ==="
|
|
15
16
|
|
|
16
17
|
SYNC_SH="$REPO_ROOT/scripts/sync-skills.sh"
|
|
17
18
|
SETUP_JS="$REPO_ROOT/bin/setup.js"
|
|
18
19
|
|
|
19
|
-
grep -q -- '--distribute-only' "$SYNC_SH" &&
|
|
20
|
-
||
|
|
21
|
-
grep -q "sync-skills.sh --distribute-only" "$SETUP_JS" &&
|
|
22
|
-
||
|
|
20
|
+
grep -q -- '--distribute-only' "$SYNC_SH" && ta_pass 'sync-skills.sh: --distribute-only flag defined' \
|
|
21
|
+
|| ta_fail 'sync-skills.sh: missing --distribute-only flag'
|
|
22
|
+
grep -q "sync-skills.sh --distribute-only" "$SETUP_JS" && ta_pass 'setup.js: invokes sync-skills.sh with --distribute-only' \
|
|
23
|
+
|| ta_fail 'setup.js: does not pass --distribute-only'
|
|
23
24
|
grep -q "runInheritedAsync('bash scripts/sync-skills.sh --distribute-only')" "$SETUP_JS" \
|
|
24
|
-
&&
|
|
25
|
-
||
|
|
25
|
+
&& ta_pass 'setup.js: sync-skills call is async (spinner can animate)' \
|
|
26
|
+
|| ta_fail 'setup.js: sync-skills call reverted to blocking runInherited (spinner would freeze)'
|
|
26
27
|
|
|
27
28
|
hash_of() { [[ -f "$1" ]] && shasum -a 256 "$1" | awk '{print $1}' || echo "absent"; }
|
|
28
29
|
listing_of() { [[ -d "$1" ]] && (find "$1" -maxdepth 1 -type f | sort) || echo "absent"; }
|
|
@@ -34,29 +35,29 @@ EPICS_WIKI_BEFORE=$(listing_of "$REPO_ROOT/specs/epics-wiki")
|
|
|
34
35
|
|
|
35
36
|
OUT="$(cd "$REPO_ROOT" && bash scripts/sync-skills.sh --distribute-only 2>&1)"
|
|
36
37
|
echo "$OUT" | grep -q -- '--distribute-only: dev-maintenance regen skipped' \
|
|
37
|
-
&&
|
|
38
|
-
||
|
|
38
|
+
&& ta_pass 'sync-skills.sh --distribute-only: confirmation message printed' \
|
|
39
|
+
|| ta_fail 'sync-skills.sh --distribute-only: missing confirmation message'
|
|
39
40
|
echo "$OUT" | grep -q 'Generating OKF wikis' \
|
|
40
|
-
&&
|
|
41
|
-
||
|
|
41
|
+
&& ta_fail 'sync-skills.sh --distribute-only: still generated OKF wikis' \
|
|
42
|
+
|| ta_pass 'sync-skills.sh --distribute-only: no OKF wiki generation'
|
|
42
43
|
echo "$OUT" | grep -q 'regenerate-lockfile' \
|
|
43
|
-
&&
|
|
44
|
-
||
|
|
44
|
+
&& ta_fail 'sync-skills.sh --distribute-only: still regenerated lockfile' \
|
|
45
|
+
|| ta_pass 'sync-skills.sh --distribute-only: no lockfile regen'
|
|
45
46
|
|
|
46
47
|
[[ "$(hash_of "$REPO_ROOT/skills-lock.json")" == "$LOCK_BEFORE" ]] \
|
|
47
|
-
&&
|
|
48
|
+
&& ta_pass 'skills-lock.json untouched' || ta_fail 'skills-lock.json was modified'
|
|
48
49
|
[[ "$(hash_of "$REPO_ROOT/SKILL-INDEX.md")" == "$INDEX_BEFORE" ]] \
|
|
49
|
-
&&
|
|
50
|
+
&& ta_pass 'SKILL-INDEX.md untouched' || ta_fail 'SKILL-INDEX.md was modified'
|
|
50
51
|
[[ "$(hash_of "$REPO_ROOT/specs/SKILL-SEARCH-INDEX_LATEST.md")" == "$SEARCH_INDEX_BEFORE" ]] \
|
|
51
|
-
&&
|
|
52
|
+
&& ta_pass 'SKILL-SEARCH-INDEX_LATEST.md untouched' || ta_fail 'SKILL-SEARCH-INDEX_LATEST.md was modified'
|
|
52
53
|
[[ "$(listing_of "$REPO_ROOT/specs/epics-wiki")" == "$EPICS_WIKI_BEFORE" ]] \
|
|
53
|
-
&&
|
|
54
|
+
&& ta_pass 'specs/epics-wiki/ untouched' || ta_fail 'specs/epics-wiki/ was modified'
|
|
54
55
|
|
|
55
|
-
[[ -f "$REPO_ROOT/.cursor/rules/fix-bug.mdc" ]] &&
|
|
56
|
-
||
|
|
56
|
+
[[ -f "$REPO_ROOT/.cursor/rules/fix-bug.mdc" ]] && ta_pass 'skills still distributed (.cursor/rules populated)' \
|
|
57
|
+
|| ta_fail 'skill distribution did not run'
|
|
57
58
|
|
|
58
|
-
bash -n "$SYNC_SH" &&
|
|
59
|
-
node --check "$SETUP_JS" &&
|
|
59
|
+
bash -n "$SYNC_SH" && ta_pass 'bash -n sync-skills.sh' || ta_fail 'bash -n sync-skills.sh'
|
|
60
|
+
node --check "$SETUP_JS" && ta_pass 'node --check setup.js' || ta_fail 'node --check setup.js'
|
|
60
61
|
|
|
61
|
-
echo "test-install-distribute-only: $
|
|
62
|
-
[[ "$
|
|
62
|
+
echo "test-install-distribute-only: $TA_PASS passed, $TA_FAIL failed"
|
|
63
|
+
[[ "$TA_FAIL" -eq 0 ]] || exit 1
|
|
@@ -19,10 +19,12 @@ source "$(dirname "${BASH_SOURCE[0]}")/lib/skill-common.sh"
|
|
|
19
19
|
resolve_repo_root
|
|
20
20
|
cd "$REPO_ROOT"
|
|
21
21
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
22
|
+
TA_PASS=0
|
|
23
|
+
TA_FAIL=0
|
|
24
|
+
TA_TMPDIR=""
|
|
25
|
+
|
|
26
|
+
source "$(dirname "${BASH_SOURCE[0]}")/lib/test-assertions.sh"
|
|
27
|
+
trap ta_cleanup EXIT
|
|
26
28
|
|
|
27
29
|
INSTALL_SH="scripts/install.sh"
|
|
28
30
|
HELPERS_JS="scripts/lib/install-helpers.js"
|
|
@@ -82,7 +84,7 @@ alias_target_for() {
|
|
|
82
84
|
echo "=== test-install-hub.sh ==="
|
|
83
85
|
|
|
84
86
|
TARGETS=$(discover_targets)
|
|
85
|
-
[[ -n "$TARGETS" ]] || {
|
|
87
|
+
[[ -n "$TARGETS" ]] || { ta_fail "no install_<id>() functions discovered"; echo "test-install-hub: $TA_PASS passed, $TA_FAIL failed"; exit 1; }
|
|
86
88
|
echo "Discovered $(wc -w <<<"$TARGETS" | tr -d ' ') install targets"
|
|
87
89
|
|
|
88
90
|
DRY_OUT="$(bash "$INSTALL_SH" --dry-run 2>&1 || true)"
|
|
@@ -92,41 +94,41 @@ SETUP_IDS="$(sed -n '/SUPPORTED_IDS = new Set/,/);/p' "$SETUP_JS")"
|
|
|
92
94
|
for id in $TARGETS; do
|
|
93
95
|
# shellcheck disable=SC2086
|
|
94
96
|
grep -qE "^uninstall_${id}\(\)" $INSTALL_SRC \
|
|
95
|
-
&&
|
|
96
|
-
||
|
|
97
|
+
&& ta_pass "$id: uninstall_${id}() defined" \
|
|
98
|
+
|| ta_fail "$id: uninstall_${id}() missing"
|
|
97
99
|
|
|
98
100
|
# Some targets are pure aliases (install_antigravity just calls install_agy).
|
|
99
101
|
# They own no label; the delegate's label is asserted on its own pass.
|
|
100
102
|
alias_of="$(alias_target_for "$id")"
|
|
101
103
|
label="$(label_for "$id")"
|
|
102
104
|
if [[ -z "$label" && -n "$alias_of" ]]; then
|
|
103
|
-
|
|
105
|
+
ta_pass "$id: alias of $alias_of (label asserted there)"
|
|
104
106
|
elif [[ -z "$label" ]]; then
|
|
105
|
-
|
|
107
|
+
ta_fail "$id: no 'Label →' line found inside install_${id}()"
|
|
106
108
|
else
|
|
107
109
|
grep -qF "$label →" <<<"$DRY_OUT" \
|
|
108
|
-
&&
|
|
109
|
-
||
|
|
110
|
+
&& ta_pass "$id: dry-run shows '$label'" \
|
|
111
|
+
|| ta_fail "$id: dry-run missing '$label' section"
|
|
110
112
|
grep -qF "$label →" <<<"$DRY_UNINSTALL" \
|
|
111
|
-
&&
|
|
112
|
-
||
|
|
113
|
+
&& ta_pass "$id: dry-run --uninstall shows '$label'" \
|
|
114
|
+
|| ta_fail "$id: dry-run --uninstall missing '$label' section"
|
|
113
115
|
fi
|
|
114
116
|
|
|
115
117
|
grep -q "case '${id}'" "$HELPERS_JS" \
|
|
116
|
-
&&
|
|
117
|
-
||
|
|
118
|
+
&& ta_pass "$id: install-helpers case" \
|
|
119
|
+
|| ta_fail "$id: install-helpers missing case '${id}'"
|
|
118
120
|
|
|
119
121
|
sid="$(setup_id_for "$id")"
|
|
120
122
|
grep -q "'${sid}'" <<<"$SETUP_IDS" \
|
|
121
|
-
&&
|
|
122
|
-
||
|
|
123
|
+
&& ta_pass "$id: setup.js SUPPORTED_IDS carries '${sid}'" \
|
|
124
|
+
|| ta_fail "$id: setup.js SUPPORTED_IDS missing '${sid}'"
|
|
123
125
|
done
|
|
124
126
|
|
|
125
127
|
# Global syntax gates — previously repeated in all 14 scripts.
|
|
126
|
-
bash -n "$INSTALL_SH" &&
|
|
127
|
-
node --check "$HELPERS_JS" >/dev/null 2>&1 &&
|
|
128
|
-
node --check "$SETUP_JS" >/dev/null 2>&1 &&
|
|
129
|
-
grep -q "SUPPORTED_IDS = new Set" "$SETUP_JS" &&
|
|
128
|
+
bash -n "$INSTALL_SH" && ta_pass "bash -n install.sh" || ta_fail "bash -n install.sh"
|
|
129
|
+
node --check "$HELPERS_JS" >/dev/null 2>&1 && ta_pass "node --check install-helpers.js" || ta_fail "node --check install-helpers.js"
|
|
130
|
+
node --check "$SETUP_JS" >/dev/null 2>&1 && ta_pass "node --check setup.js" || ta_fail "node --check setup.js"
|
|
131
|
+
grep -q "SUPPORTED_IDS = new Set" "$SETUP_JS" && ta_pass "setup.js defines SUPPORTED_IDS" || ta_fail "setup.js missing SUPPORTED_IDS"
|
|
130
132
|
|
|
131
133
|
# Registry coverage is reported, not enforced: copilot, opencode, claude and
|
|
132
134
|
# antigravity ship install functions but have no targets.yaml row today.
|
|
@@ -135,5 +137,5 @@ for id in $TARGETS; do
|
|
|
135
137
|
grep -q "id: ${id}$" "$TARGETS_YAML" || echo " note: $id installs but has no targets.yaml row"
|
|
136
138
|
done
|
|
137
139
|
|
|
138
|
-
echo "test-install-hub: $
|
|
139
|
-
[[ "$
|
|
140
|
+
echo "test-install-hub: $TA_PASS passed, $TA_FAIL failed"
|
|
141
|
+
[[ "$TA_FAIL" -eq 0 ]] || exit 1
|
|
@@ -16,15 +16,17 @@ source "$(dirname "${BASH_SOURCE[0]}")/lib/skill-common.sh"
|
|
|
16
16
|
resolve_repo_root
|
|
17
17
|
cd "$REPO_ROOT"
|
|
18
18
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
19
|
+
TA_PASS=0
|
|
20
|
+
TA_FAIL=0
|
|
21
|
+
TA_TMPDIR=""
|
|
22
|
+
|
|
23
|
+
source "$(dirname "${BASH_SOURCE[0]}")/lib/test-assertions.sh"
|
|
24
|
+
trap ta_cleanup EXIT
|
|
23
25
|
|
|
24
26
|
# Build a throwaway PyYAML-free interpreter — a fresh venv has no PyYAML,
|
|
25
27
|
# reproducing a stock macOS python3 without touching the caller's environment.
|
|
26
|
-
|
|
27
|
-
|
|
28
|
+
TA_TMPDIR="$(mktemp -d)"
|
|
29
|
+
NOYAML_DIR="$TA_TMPDIR"
|
|
28
30
|
if ! python3 -m venv "$NOYAML_DIR/venv" >/dev/null 2>&1; then
|
|
29
31
|
echo "test-setup-no-pyyaml: SKIP — cannot create venv"; exit 0
|
|
30
32
|
fi
|
|
@@ -35,18 +37,18 @@ fi
|
|
|
35
37
|
|
|
36
38
|
# 1. srp-engine.py must parse a skill's frontmatter without crashing.
|
|
37
39
|
if "$NOPY" scripts/lib/srp-engine.py skills/fix-bug/SKILL.md >/dev/null 2>&1; then
|
|
38
|
-
|
|
40
|
+
ta_pass "srp-engine.py parses frontmatter without PyYAML"
|
|
39
41
|
else
|
|
40
|
-
|
|
42
|
+
ta_fail "srp-engine.py crashed without PyYAML"
|
|
41
43
|
fi
|
|
42
44
|
|
|
43
45
|
# 2. validate-skill-yaml.py must not bail with exit 2 (the old PyYAML-required path).
|
|
44
46
|
rc=0
|
|
45
47
|
"$NOPY" scripts/validate-skill-yaml.py >/dev/null 2>&1 || rc=$?
|
|
46
48
|
if [[ "$rc" -ne 2 ]]; then
|
|
47
|
-
|
|
49
|
+
ta_pass "validate-skill-yaml.py runs without PyYAML (exit $rc)"
|
|
48
50
|
else
|
|
49
|
-
|
|
51
|
+
ta_fail "validate-skill-yaml.py bailed with exit 2 (PyYAML required)"
|
|
50
52
|
fi
|
|
51
53
|
|
|
52
54
|
# 3. Fallback fidelity: simple_yaml must equal PyYAML for every skill's
|
|
@@ -71,13 +73,10 @@ if bad:
|
|
|
71
73
|
print("mismatch: " + ", ".join(bad)); sys.exit(1)
|
|
72
74
|
sys.exit(0)
|
|
73
75
|
PY
|
|
74
|
-
|
|
76
|
+
ta_pass "simple_yaml matches PyYAML for all skill frontmatter"
|
|
75
77
|
else
|
|
76
|
-
|
|
78
|
+
ta_fail "simple_yaml diverged from PyYAML for some skill frontmatter"
|
|
77
79
|
fi
|
|
78
80
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
exit 1
|
|
82
|
-
fi
|
|
83
|
-
echo "test-setup-no-pyyaml: PASS"
|
|
81
|
+
echo "test-setup-no-pyyaml: $TA_PASS passed, $TA_FAIL failed"
|
|
82
|
+
[[ "$TA_FAIL" -eq 0 ]] || exit 1
|