From 3b1527a56f2000bc80254be6deb272c0b2b9d02f Mon Sep 17 00:00:00 2001 From: ShuaixinHuang <1836656514@qq.com> Date: Fri, 20 Nov 2026 06:27:50 +0800 Subject: [PATCH] test(hopper): allow a pending launcher exit at startup timeout (#12544) Co-authored-by: ShuaixinHuang --- .../providers/hopperStartupRecovery.test.ts | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/tests/acceptance/providers/hopperStartupRecovery.test.ts b/tests/acceptance/providers/hopperStartupRecovery.test.ts index 1f73eab9f8..59c1a6e671 100644 --- a/tests/acceptance/providers/hopperStartupRecovery.test.ts +++ b/tests/acceptance/providers/hopperStartupRecovery.test.ts @@ -330,7 +330,17 @@ test.for(["handoff", "not-found"] as const)( : "provider_unavailable", details: launchMode === "handoff" - ? { timeout_ms: startupTimeoutMs, launcher: { exit_code: 0 } } + ? { + timeout_ms: startupTimeoutMs, + launcher: { + // The receipt proves launch. The deadline snapshot may + // precede delivery of the successful child exit event. + exit_code: expect.toSatisfy( + (exitCode: unknown) => + exitCode === null || exitCode === 0, + ), + }, + } : { stage: "launch", launcher: { exit_code: 3 } }, }, },