Each build module parsed its own test runner's output, so a fix in one never reached the others: a failed node --test run was worded by a passing line of its first file. buildstep.Failure names the test, its file, its cause and its own output; ReadGoTest (moved from mesh-build-go) and ReadTAP fill it; package conformance holds every build module to it with runner output captured with the build nodes' own toolchains.
1.6 KiB
1.6 KiB
TAP version 13
# Subtest: passes in the first file
ok 1 - passes in the first file
---
duration_ms: 0.637465
type: 'test'
...
# node:internal/modules/run_main:111
# triggerUncaughtException(
# ^
# file:///tmp/1901k/node/syntax/test/b.test.ts:2
# test('never loads', () => {
# SyntaxError [ERR_INVALID_TYPESCRIPT_SYNTAX]: Expected ',', got '<eof>'
# at parseTypeScript (node:internal/modules/typescript:61:36)
# at processTypeScriptCode (node:internal/modules/typescript:129:37)
# at Object.stripTypeScriptModuleTypes (node:internal/modules/typescript:172:22)
# at stripTypeScriptModuleTypes (node:internal/modules/esm/translators:35:49)
# at ModuleLoader.<anonymous> (node:internal/modules/esm/translators:688:29)
# at \#translate (node:internal/modules/esm/loader:441:20)
# at afterLoad (node:internal/modules/esm/loader:509:29)
# at ModuleLoader.loadAndTranslate (node:internal/modules/esm/loader:514:12)
# at \#getOrCreateModuleJobAfterResolve (node:internal/modules/esm/loader:567:36)
# at afterResolve (node:internal/modules/esm/loader:614:52) {
# code: 'ERR_INVALID_TYPESCRIPT_SYNTAX'
# }
# Node.js v26.12.1
# Subtest: test/b.test.ts
not ok 2 - test/b.test.ts
---
duration_ms: 87.629815
type: 'test'
location: '/tmp/1901k/node/syntax/test/b.test.ts:1:1'
failureType: 'testCodeFailure'
exitCode: 1
signal: ~
error: 'test failed'
code: 'ERR_TEST_FAILURE'
...
1..2
# tests 2
# suites 0
# pass 1
# fail 1
# cancelled 0
# skipped 0
# todo 0
# duration_ms 106.551435
# Subtest: passes in the first file
ok 1 - passes in the first file
---
duration_ms: 0.637465
type: 'test'
...
# node:internal/modules/run_main:111
# triggerUncaughtException(
# ^
# file:///tmp/1901k/node/syntax/test/b.test.ts:2
# test('never loads', () => {
# SyntaxError [ERR_INVALID_TYPESCRIPT_SYNTAX]: Expected ',', got '<eof>'
# at parseTypeScript (node:internal/modules/typescript:61:36)
# at processTypeScriptCode (node:internal/modules/typescript:129:37)
# at Object.stripTypeScriptModuleTypes (node:internal/modules/typescript:172:22)
# at stripTypeScriptModuleTypes (node:internal/modules/esm/translators:35:49)
# at ModuleLoader.<anonymous> (node:internal/modules/esm/translators:688:29)
# at \#translate (node:internal/modules/esm/loader:441:20)
# at afterLoad (node:internal/modules/esm/loader:509:29)
# at ModuleLoader.loadAndTranslate (node:internal/modules/esm/loader:514:12)
# at \#getOrCreateModuleJobAfterResolve (node:internal/modules/esm/loader:567:36)
# at afterResolve (node:internal/modules/esm/loader:614:52) {
# code: 'ERR_INVALID_TYPESCRIPT_SYNTAX'
# }
# Node.js v26.12.1
# Subtest: test/b.test.ts
not ok 2 - test/b.test.ts
---
duration_ms: 87.629815
type: 'test'
location: '/tmp/1901k/node/syntax/test/b.test.ts:1:1'
failureType: 'testCodeFailure'
exitCode: 1
signal: ~
error: 'test failed'
code: 'ERR_TEST_FAILURE'
...
1..2
# tests 2
# suites 0
# pass 1
# fail 1
# cancelled 0
# skipped 0
# todo 0
# duration_ms 106.551435