- Add fast `test-timeout` guard chaining `test-timeout-lua`/`-shell` - Wire `test-timeout` into `just ci` for harness regression coverage - Consolidate fixtures into single `tests/harness/slow-case.lua` - Tighten timeouts (libtest 2s / shell watchdog 3s) so each check is ~3s - Update ADR-0009 and DEVELOPMENT.md for the new recipes and ci wiring
17 lines
715 B
Lua
17 lines
715 B
Lua
-- Harness fixture (NOT auto-discovered: lives under tests/harness/).
|
|
-- A single case that sleeps well past any harness timeout. The driving recipe
|
|
-- decides which layer cancels it: `test-timeout-lua` lets libtest fire via
|
|
-- `--timeout`, `test-timeout-shell` bypasses libtest (`--no-timeout`) so the
|
|
-- shell watchdog kills the process. See `just test-timeout`.
|
|
local createLibTest = require('/apis/libtest');
|
|
|
|
local testlib = createLibTest({ ... });
|
|
|
|
testlib.test('sleeps past the harness timeout', function()
|
|
testlib.log('about to sleep 10s; the active harness timeout should cancel this first');
|
|
sleep(10);
|
|
testlib.assertTrue(true); -- never reached: a timeout layer cancels first
|
|
end);
|
|
|
|
testlib.run();
|