tests-that-observe

Classifies tests as behavioural or source-text and enforces ledger, pairing, and mutation-proof artifacts before writing tests.

Updated Jun 22, 2026
Ready to run
npx skills add https://github.com/jtjones09/grabbr-hops --skill tests-that-observe-jtjones09
💬 Prompt for ChatGPT / Claude Chat▼
Please help me install this Agent Skill.
Skill: tests-that-observe
Source: https://github.com/jtjones09/grabbr-hops/tree/main/.claude/skills/tests-that-observe
Command: npx skills add https://github.com/jtjones09/grabbr-hops --skill tests-that-observe-jtjones09

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Test suites often verify the repository's own source text (via include_str!, greps, or string assertions) instead of observing the running product, so suites stay green while real cross-crate, cross-binary, or cross-machine features are broken. This Skill forces every test to be classified and backed by behavioural evidence before it is written or cited. ## Core Features & Use Cases - Test Ledger Discipline: Emits a TEST LEDGER table classifying every test as class B (behavioural, via one of six observation channels) or class S (source-text) before any test code is written, with LEDGER tags above each test function. - Guard Pairing & Two-Ended Checks: Requires every source-text guard to name a paired behavioural test covering the same property, and requires producer-first, both-sides verification for features spanning crates, binaries, or hosts. - Mutation Proof & Evidence Rules: Demands a pasted FAIL/PASS mutation proof per property, forbids citing green CI or test counts as evidence, and blocks PRs that lack the ledger section. - Use Case: When implementing a pairing ceremony where two machines must display the same verification code, the Skill stops you from shipping a guard asserting the instruction text exists and instead surfaces that the receiver never computes the code. ## Quick Start Before writing or editing any test, ask the assistant to apply the tests-that-observe skill and emit the TEST LEDGER classifying each planned test as behavioural or source-text.

Frequently Asked Questions about tests-that-observe

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write tests that verify behaviour instead of source code?▼

Classify each test against six observation channels: return values, bytes on a socket, rendered pixels or widget trees, files on disk, process output, or struct state after running real code. If a test only reads source files or asserts a string exists, it is a source-text guard and must be paired with a behavioural test.

What is wrong with using include_str! in tests?▼

include_str! tests read the repository's own source text, so they pass even when the product is broken because each code fragment contains its own text. They also self-match, since the guard's assertion text lives in the file it scans. Such guards must be paired with a behavioural test or deleted.

How do I test a feature that spans two machines or crates?▼

Write the producing side's behavioural test first and paste its passing run line before writing the consuming side's test. If the producing side cannot produce the value in a test, that is the bug; stop and report it rather than shipping a guard on the instruction text.

Why should a test that passed on its first run be distrusted?▼

A test that has never failed is unverified because it may assert nothing. Mutation testing reintroduces the real defect into the production code path and confirms the test fails, then passes again after reverting, proving the test actually observes the property.

Can green CI be cited as evidence that a feature works?▼

No. Green CI, test counts, and the existence of code are explicitly not evidence. A claim that software works must cite a behavioural test id plus the pasted summary line of the run that included it, or be marked UNVERIFIED.

What should I do when a test starts failing after a change?▼

Treat the red test as the finding and stop. Do not delete it, ignore it, loosen assertions, widen tolerances, or wrap it in should_panic to make the suite green again; report the failure instead.