# Gate 1 — behavior-proof

**Question:** do the tests assert what the code produces, or only that it ran?

## Why this is first

This is the check the whole kit exists for. An agent optimises for the signal
it is given. Tell it "make the tests pass" and it will make the tests pass —
sometimes by writing tests that cannot fail. A suite of `expect(result).toBeDefined()`
is green and proves nothing. Ten passing tests can still fail a merge.

## The automated pass

The CLI fails the gate when production code changed and no test changed with it,
and warns when a changed test contains an assertion that checks existence or
non-failure but never compares against an expected value.

## What the machine cannot judge — record it here

- [ ] Each new behaviour has a test that would **fail if the behaviour were wrong**,
      not merely if it threw.
- [ ] The test asserts the *output*, not that a function was called.
- [ ] Edge cases named in the task have a case each (empty, boundary, error path).
- [ ] No test was weakened or deleted to make the suite pass.
- [ ] A test you expected to fail before the change actually did.

## Failure looks like

- Snapshot tests regenerated to match whatever the code now emits.
- `try { ... } catch { }` swallowing the assertion.
- A mock asserting it was called, with no assertion on the result.
- Coverage up, behaviour unproven.

## Evidence to attach

The one test you wrote first that failed, and the diff that made it pass.
