# Integer validator: two recorded red/green cycles

The isolated exercise began with an exported function scaffold containing no behavior and one assertion that zero should be accepted. The actual command failed with undefined !== true. This was the missing behavior assertion, not a missing import or test-runner error.

The smallest first implementation returned true. The zero test passed. The remaining five cases were then added to the contract suite. Running those six tests against the first implementation produced two passes and four failures, demonstrating the missing rejection behavior.

The final implementation is Number.isInteger(value) && value >= 0. The actual final suite passed all six cases: 0 and 7 true; -1, 1.5, null and string 7 false. Historical source and test snapshots for red-zero, green-zero and red-contract preserve each stage. commands.jsonl records the real order, timestamps, streams and exit codes.

The full active suite is contract.test.mjs. Historical snapshots are deliberately run individually; an indiscriminate test discovery over every historical snapshot would include expected failing versions. The replay script runs each with its documented expected exit code.

No production files were changed for this exercise. This is evidence that the requested process and contract checks ran, not a performance comparison against a no-skill agent.

## Provenance

Pinned source: [obra/superpowers at 8ca22dba9a94f28898bbce59f2537ff4d87c747d](https://github.com/obra/superpowers/blob/8ca22dba9a94f28898bbce59f2537ff4d87c747d/skills/test-driven-development/SKILL.md). Exact source hashes and references are in sources.json.

Executed on 2026-10-04 by Codex in this conversation using Node.js 24.13.0 and Python 3.12.3 on Linux. The exact model version was not exposed. Original command timestamps and stream hashes are in commands.jsonl. These records do not establish independent human adoption, customer outcomes or a compatibility certification.
