make the agent always load the write-tests skill before writing a test
Adding the rule to the agent prompt.
AGENT.md
1## Rules
+2- Before writing any *.test.ts file, load the write-tests skill.
Problem
make the agent always load the write-tests skill before writing a test
Adding the rule to the agent prompt.
Blocked: a prompt rule is probabilistic — a must-be-loaded precondition needs a file-guard that intercepts the write.
file_path:
AGENT.md
old_string:
## Rules
new_string:
## Rules - Before writing any *.test.ts file, load the write-tests skill.
Right — making it a real precondition guard instead of a prompt line.
.sloprail/file-guard/require-write-tests-skill/file-guard.yaml
+1match: "**/*.test.ts"
+2preventive: true
+3require:
+4 - skill: write-tests
Solution