fix(docker): keep upgrade survivor auto-auth summary safe · openclaw/openclaw@0f67474
vincentkoc
·
2026-06-21
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -2342,6 +2342,26 @@ fi
|
2342 | 2342 | ); |
2343 | 2343 | }); |
2344 | 2344 | |
| 2345 | +it("keeps upgrade survivor auto-auth success summary set -u safe", () => { |
| 2346 | +const runner = readFileSync(UPGRADE_SURVIVOR_DOCKER_E2E_PATH, "utf8"); |
| 2347 | + |
| 2348 | +const summaryDefaultIndex = runner.indexOf('startup_summary="n/a"'); |
| 2349 | +const autoAuthIndex = runner.indexOf( |
| 2350 | +'if [ "$UPDATE_RESTART_MODE" = "auto-auth" ]; then', |
| 2351 | +summaryDefaultIndex, |
| 2352 | +); |
| 2353 | +const manualSummaryIndex = runner.indexOf('startup_summary="${start_seconds}s"', autoAuthIndex); |
| 2354 | +const successIndex = runner.indexOf( |
| 2355 | +"startup=${startup_summary} status=${status_seconds}s", |
| 2356 | +manualSummaryIndex, |
| 2357 | +); |
| 2358 | + |
| 2359 | +expect(summaryDefaultIndex).toBeGreaterThan(-1); |
| 2360 | +expect(autoAuthIndex).toBeGreaterThan(summaryDefaultIndex); |
| 2361 | +expect(manualSummaryIndex).toBeGreaterThan(autoAuthIndex); |
| 2362 | +expect(successIndex).toBeGreaterThan(manualSummaryIndex); |
| 2363 | +}); |
| 2364 | + |
2345 | 2365 | it.each([ |
2346 | 2366 | ["start budget", "OPENCLAW_UPGRADE_SURVIVOR_START_BUDGET_SECONDS", "90s"], |
2347 | 2367 | ["status budget", "OPENCLAW_UPGRADE_SURVIVOR_STATUS_BUDGET_SECONDS", "30s"], |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。