npx vitest run # the whole suite
npx vitest run <file> # one fileEvery test is hermetic — pure libs, injected fs/clock, fixtures. Nothing touches a live Beeper, a real profile, or the network. A green suite is the bar for any change.
- Unit / behavior (
tests/*.test.mjs) — the bulk. Each CONTRACTS invariant earns a test.tests/integrity.test.mjsfails ifegpt.mjsreads a config key not registered inconfig/config-schema.mjs. - Boot-profile contract (
tests/boot-profile-contract.test.mjs) — boots the REAL spine against an on-disk fixture in the canonical layout with NO path overrides; the tripwire for a relayout that slips past the unit suite. - Install verify (
node setup/verify-install.mjs [egptHome]) — read-only, NOT in vitest. Probes the LIVE node: the Session 1 task (log under config/logs) and the Session 0 service, profile shape,spine.pid/alive.txtliveness,claudeon PATH. Exit 0 = healthy.
Ad-hoc live probes (real Beeper / CDP / audio) live in tests-manual/ — run by hand, never in CI.
Set EGPT_HOME to a temp dir for anything that touches a profile — never the
production ~/.egpt.
tests/transcriptor.test.mjs and tests/beeper-bridge.test.mjs ("newest
isSender match") can fail only under full-suite port/timing contention. Both pass
alone. If one is the sole red, re-run it isolated (npx vitest run tests/<file>)
to confirm it's the flake, not a regression.