mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2026-11-08 11:46:35 +00:00
The routine only carried an EXIT trap, so a run terminated by the enclosing `timeout` in distros.sh:128 left no rescue diagnostics, no playwright reports and no teardown — the exact case where the artifacts matter most. Add a TERM trap and make the handler take the status as an argument, so EXIT keeps using `$?` while TERM passes 143 explicitly. The `_teardown_done` latch is required because the EXIT trap still fires after the TERM trap; without it the whole collect-and-teardown block, including its 1500s and 900s timeouts, would run twice. This works because GNU timeout signals the whole process group: bash defers a trap while it waits on a foreground child, so a bare kill to the script PID alone would not surface it until that child exited. Reproduced under the real shape (timeout -k): TEARDOWN rc=143, exactly once, after 2.01s. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Test Utilities 🧪
This directory holds the operational side of testing in Infinito.Nexus.
These assets are meant to support confidence, not ceremony. They help the project validate real-world behavior across local development, CI environments, and deployment-oriented smoke tests. The emphasis is on practical feedback: when something breaks, the surrounding test tooling should make the failure easier to understand, easier to reproduce, and easier to clean up. 🚀
Good changes in this area usually make the test experience more:
- repeatable
- diagnosable
- environment-aware
- safe to rerun
The ideal outcome is boring reliability: contributors should be able to trust that a test run says something meaningful about the system, not just about the machine that happened to execute it. ✅