fix(e2e): clean Codex plugin live artifacts · openclaw/openclaw@a5653c0
vincentkoc
·
2026-05-26
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -21,6 +21,8 @@ const OPENWEBUI_DOCKER_E2E_PATH = "scripts/e2e/openwebui-docker.sh";
|
21 | 21 | const ONBOARD_DOCKER_E2E_PATH = "scripts/e2e/onboard-docker.sh"; |
22 | 22 | const KITCHEN_SINK_PLUGIN_DOCKER_E2E_PATH = "scripts/e2e/kitchen-sink-plugin-docker.sh"; |
23 | 23 | const KITCHEN_SINK_RPC_DOCKER_E2E_PATH = "scripts/e2e/kitchen-sink-rpc-docker.sh"; |
| 24 | +const CODEX_NPM_PLUGIN_LIVE_DOCKER_E2E_PATH = |
| 25 | +"scripts/e2e/codex-npm-plugin-live-docker.sh"; |
24 | 26 | const PLUGIN_BINDING_COMMAND_ESCAPE_DOCKER_E2E_PATH = |
25 | 27 | "scripts/e2e/plugin-binding-command-escape-docker.sh"; |
26 | 28 | const PLUGIN_BINDING_COMMAND_ESCAPE_DOCKERFILE_PATH = |
@@ -346,6 +348,18 @@ test -f "$external_dir/openclaw-current.tgz"
|
346 | 348 | } |
347 | 349 | }); |
348 | 350 | |
| 351 | +it("cleans Codex npm plugin live package artifacts on every exit path", () => { |
| 352 | +const runner = readFileSync(CODEX_NPM_PLUGIN_LIVE_DOCKER_E2E_PATH, "utf8"); |
| 353 | + |
| 354 | +expect(runner).toContain('CODEX_PLUGIN_PACK_DIR=""'); |
| 355 | +expect(runner).toContain('run_log=""'); |
| 356 | +expect(runner).toMatch( |
| 357 | +/cleanup\(\) \{[\s\S]*rm -rf "\$CODEX_PLUGIN_PACK_DIR"[\s\S]*docker_e2e_cleanup_package_tgz "\$PACKAGE_TGZ"[\s\S]*rm -f "\$run_log"/u, |
| 358 | +); |
| 359 | +expect(runner).toContain("trap cleanup EXIT"); |
| 360 | +expect(runner).not.toContain('rm -f "$run_log"\n exit 1'); |
| 361 | +}); |
| 362 | + |
349 | 363 | it("includes procps in the shared Docker E2E image for process watchdogs", () => { |
350 | 364 | const dockerfile = readFileSync("scripts/e2e/Dockerfile", "utf8"); |
351 | 365 | |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。