Tests MUST run selected and cached: a test runs where anything it transitively imports changed (relative imports, and the packages of the libraries through their exports), where a requirement named on a // Spec: line of a changed file (or the specification a changed file belongs to) is proved by it, and, for a seam, where its library imports a changed symbol of the provider (or every symbol); a test of a suite that reads the checkout (CHECKOUT, import.meta, process.cwd) MUST never be left out nor cached (a seam runs only the tests that import the changed symbols); a test left out MUST be reported with the reason tests-unaffected. The result of a test MUST be kept in a cache outside the repository (the cache folder of XDG, or REPOCTL_CACHE) under the hash of the runtime, the test and every source it imports, a failure MUST never be cached, and a test whose key is in the cache MUST not run again and MUST be reported with the reason cache-hit; --no-cache runs every selected test.
Enforced (check): .github: cd commons/repoctl && bun run verify — suite/prove-select.test.ts: selection by imports, trace and symbols, environmental tests never left out, the cache keeps passes under an exact key and a second run takes them
Proved by: repoctl/suite/prove-select.test.ts
Written in: repoctl/src/logical/select.ts, repoctl/src/physical/prove-run.ts, repoctl/src/physical/tests.ts
Tests: passed: suite/prove-select.test.ts over a real repository a passing test is cached under its key and a second run takes it, a; passed: suite/prove-select.test.ts a seam runs the tests whose library files import a changed symbol of the provider, or ever; passed: suite/prove-select.test.ts a test runs where what it imports changed, where a requirement it proves is named by a cha
Cited by: Repoctl, logical/select, physical/prove-run, physical/tests