@@ -25,6 +25,7 @@ const BUNDLED_PLUGIN_INSTALL_UNINSTALL_PROBE_PATH =
|
25 | 25 | "scripts/e2e/lib/bundled-plugin-install-uninstall/probe.mjs"; |
26 | 26 | const BUNDLED_PLUGIN_INSTALL_UNINSTALL_RUNTIME_SMOKE_PATH = |
27 | 27 | "scripts/e2e/lib/bundled-plugin-install-uninstall/runtime-smoke.mjs"; |
| 28 | +const CLEANUP_SMOKE_DOCKERFILE_PATH = "scripts/docker/cleanup-smoke/Dockerfile"; |
28 | 29 | const PLUGINS_DOCKER_E2E_PATH = "scripts/e2e/plugins-docker.sh"; |
29 | 30 | const PLUGINS_DOCKER_SWEEP_PATH = "scripts/e2e/lib/plugins/sweep.sh"; |
30 | 31 | const PLUGINS_DOCKER_MARKETPLACE_PATH = "scripts/e2e/lib/plugins/marketplace.sh"; |
@@ -107,6 +108,22 @@ describe("docker build helper", () => {
|
107 | 108 | expect(dockerfile).toContain("procps"); |
108 | 109 | }); |
109 | 110 | |
| 111 | +it("copies root lifecycle scripts before cleanup-smoke installs dependencies", () => { |
| 112 | +const dockerfile = readFileSync(CLEANUP_SMOKE_DOCKERFILE_PATH, "utf8"); |
| 113 | +const installIndex = dockerfile.indexOf("pnpm install --frozen-lockfile"); |
| 114 | + |
| 115 | +for (const script of [ |
| 116 | +"scripts/preinstall-package-manager-warning.mjs", |
| 117 | +"scripts/postinstall-bundled-plugins.mjs", |
| 118 | +"scripts/prepare-git-hooks.mjs", |
| 119 | +]) { |
| 120 | +const copyIndex = dockerfile.indexOf(script); |
| 121 | + |
| 122 | +expect(copyIndex, script).toBeGreaterThanOrEqual(0); |
| 123 | +expect(copyIndex, script).toBeLessThan(installIndex); |
| 124 | +} |
| 125 | +}); |
| 126 | + |
110 | 127 | it("preserves pnpm lookup paths for scheduled Docker child lanes", () => { |
111 | 128 | const scheduler = readFileSync(DOCKER_ALL_SCHEDULER_PATH, "utf8"); |
112 | 129 | |
|