fix(tests): clear NODE_TEST_CONTEXT for nested node --test in two suites (#1508)

test-foundation.sh and test-discord.sh ran a nested node --test that would
exit 0 on failure under a parent runner. Both clear the variable now, and
each has a check that fails the suite if it comes back. Darkwing wrote it,
Filbert approved it (e464be6c). Nine suites green on an index export.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
2026-09-26 19:10:31 -05:00
co-authored by Claude Opus 5.5
parent 34a72af912
commit 08bd3a4cc5
8 changed files with 175 additions and 14 deletions
+11
View File
@@ -3266,3 +3266,14 @@ reports 107/107 node tests and 22/22 mutations caught. The canonical
suite list in AGENTS.md. Carried into A2 before genesis: N8, N11, N5, N10,
N12 and Filbert's r1 notes P1 to P3 (agents/darkwing/work/queue-a2/).
The nested `node --test` fix (N13) is a separate commit.
## 2026-09-27: Nested node --test fix in two suites (N13, #1508)
`test-foundation.sh` and `test-discord.sh` started a nested `node --test`
that inherited NODE_TEST_CONTEXT, so under a parent runner a failing
test there would exit 0. Both now clear it, and each has one new check
that fails the suite if the clearing is lost (foundation 43 to 44,
discord 63 to 64). Darkwing wrote it (n13.patch 00868b2f; the suites
hash 60f04822 and 2ad3be74), and Filbert approved it (e464be6c). The
nine suites passed on an index export. Latent until now: nothing ran
those suites under a node runner.