(requirements = ['req1', 'req2'])
| 15 | // ─── Helpers ───────────────────────────────────────────────────────────────── |
| 16 | |
| 17 | function makeLoop(requirements = ['req1', 'req2']) { |
| 18 | const stateFile = path.join(os.tmpdir(), `tdd_harness_${Math.random().toString(36).slice(2)}.json`); |
| 19 | const state = new TDDStateMachine({ workdir: os.tmpdir(), stateFile }); |
| 20 | const gov = new TDDGovernor({ state }); |
| 21 | state.initRequirements(requirements); |
| 22 | return { state, gov }; |
| 23 | } |
| 24 | |
| 25 | // Simulate what _tddPostWrite does, but with injected test results |
| 26 | // so we don't actually run a test suite. |
no test coverage detected