Autonomous development for real products. Governed agents build from specs you approve, follow the rules you set, and nothing merges until another agent proves it. Your decisions, judgement and taste are the bar that work must clear. Declare your vision and let agents build it.
JavaScript agentic-codingai-agentsai-governanceautonomous-agentsclaude-codeclicode-reviewcodexcoding-agentsdeveloper-toolsgit-hooksllmlocal-firstmulti-agentsoftware-factoryspec-driven-developmentverificationvibe-coding
fix(core): unref runner for helper files [C7,V10]
Corey Olson643aeb1fb711
diff --git a/bin/run-tests.js b/bin/run-tests.jsindex 86b10e1e..5d666368 100644--- a/bin/run-tests.js+++ b/bin/run-tests.js@@ -61,6 +61,7 @@ function installTestWatchdog() {const timeoutMs = testTimeoutMs();const file = process.env.PULLBOARD_TEST_FILE ?? process.argv[1] ?? '<unknown test file>';const watchdog = new Worker(watchdogSource, { eval: true });+ watchdog.unref();const activeTests = new WeakMap();let nextTestId = 0;diff --git a/test/run-tests-timeout.test.js b/test/run-tests-timeout.test.jsindex c4ec1018..a1745d2a 100644--- a/test/run-tests-timeout.test.js+++ b/test/run-tests-timeout.test.js@@ -77,6 +77,27 @@ test('synchronous timeout target [C7,V10]', () => { Atomics.wait(new Int32Array(assert.match(output, /ok \d+ - later file still reports \[C7,V10\]/u);});+test('a helper-only test file exits after importing the runner [C7, V10]', (t) => {+ const root = mkdtempSync(join(tmpdir(), 'pullboard-test-timeout-helper-'));+ t.after(() => rmSync(root, { recursive: true, force: true }));+ const helper = join(root, 'helper.js');+ writeFileSync(join(root, 'package.json'), JSON.stringify({ type: 'module' }));+ writeFileSync(helper, 'export const helperLoaded = true;\n');++ const result = spawnSync(process.execPath, [runner, helper], {+ cwd: root,+ env: { ...process.env, PULLBOARD_TEST_TIMEOUT_MS: '1200' },+ encoding: 'utf8',+ detached: true,+ timeout: 10_000,+ });+ if (result.error?.code === 'ETIMEDOUT' && result.pid) {+ try { process.kill(-result.pid, 'SIGKILL'); } catch { /* The owned fixture process group already exited. */ }+ }+ assert.equal(result.status, 0, outputOf(result));+ assert.equal(result.signal, null, 'the helper exits normally without a test lifecycle');+});+test('an invalid test-timeout override refuses before running a test [C7, V10]', (t) => {const root = mkdtempSync(join(tmpdir(), 'pullboard-test-timeout-invalid-'));t.after(() => rmSync(root, { recursive: true, force: true }));