Skip to content

Commit 4cb95e3

Browse files
author
CodeWhale Bot
committed
test(runtime): expose uncaptured child panic diagnostics
A direct libtest probe showed that inheriting stderr alone still discards child panics because libtest captures them and reports failures on stdout. Pass --nocapture to both subprocess helper invocations so their inherited stderr reaches the parent test capture. Production locking is unchanged. Validation: npm test: 66 wrapper + 9 SDK + 446 web passed, 0 failed. npm run check:web passed: 0 errors, 2 existing img warnings. cargo fmt --all --check and git diff --check passed. The local panic probe verified stderr receives diagnostics with --nocapture. The complete final-commit Rust and release sweep follows this commit.
1 parent 8b39105 commit 4cb95e3

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

crates/tui/src/runtime_threads/tests.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -900,7 +900,7 @@ fn spawn_runtime_event_child(
900900
);
901901
command
902902
.arg(EVENT_PROCESS_HELPER)
903-
.args(["--exact", "--ignored", "--test-threads", "1"])
903+
.args(["--exact", "--ignored", "--nocapture", "--test-threads", "1"])
904904
.env(EVENT_PROCESS_ROLE_ENV, role)
905905
.env(EVENT_PROCESS_ROOT_ENV, root)
906906
.env(EVENT_PROCESS_THREAD_ENV, thread_id)
@@ -910,8 +910,8 @@ fn spawn_runtime_event_child(
910910
.env(EVENT_PROCESS_COUNT_ENV, "8")
911911
.stdin(std::process::Stdio::null())
912912
.stdout(std::process::Stdio::null())
913-
// The parent is captured by the test runner. Keep child panics there
914-
// so a failed writer reports its cause, not just an opaque exit 101.
913+
// Disable the child's libtest capture and inherit stderr into the
914+
// parent's capture so a failed writer reports its cause, not just 101.
915915
.stderr(std::process::Stdio::inherit());
916916
RuntimeEventChildGuard::new(command.spawn().expect("spawn Runtime event child"))
917917
}
@@ -927,7 +927,7 @@ fn spawn_runtime_manager_racer(
927927
);
928928
command
929929
.arg(EVENT_PROCESS_HELPER)
930-
.args(["--exact", "--ignored", "--test-threads", "1"])
930+
.args(["--exact", "--ignored", "--nocapture", "--test-threads", "1"])
931931
.env(EVENT_PROCESS_ROLE_ENV, "manager-racer")
932932
.env(EVENT_PROCESS_ROOT_ENV, root)
933933
.env(EVENT_PROCESS_THREAD_ENV, "thr_unused")

0 commit comments

Comments
 (0)