test: clean up Docker test-state leftovers · openclaw/openclaw@6d542eb
steipete
·
2026-04-29
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -224,10 +224,6 @@ TRASH
|
224 | 224 | run_wizard_cmd "$case_name" "$home_dir" "node \"$OPENCLAW_ENTRY\" onboard $ONBOARD_FLAGS" "$send_fn" true "$validate_fn" |
225 | 225 | } |
226 | 226 | |
227 | | - make_home() { |
228 | | - mktemp -d "/tmp/openclaw-e2e-$1.XXXXXX" |
229 | | - } |
230 | | - |
231 | 227 | set_isolated_openclaw_env() { |
232 | 228 | local label="$1" |
233 | 229 | openclaw_test_state_create "$label" empty |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -43,19 +43,11 @@ cat > \"\$HOME/.openclaw/extensions/lossless-claw/package.json\" <<'JSON'
|
43 | 43 | \"version\": \"0.9.0\" |
44 | 44 | } |
45 | 45 | JSON |
46 | | -if [ \"\$OPENCLAW_PACKAGE_ACCEPTANCE_LEGACY_COMPAT\" = \"1\" ]; then |
47 | | - cat > \"\$HOME/.openclaw/openclaw.json\" <<'JSON' |
| 46 | +cat > \"\$OPENCLAW_CONFIG_PATH\" <<'JSON' |
48 | 47 | { |
49 | 48 | \"plugins\": {} |
50 | 49 | } |
51 | 50 | JSON |
52 | | -else |
53 | | - cat > \"\$HOME/.openclaw/openclaw.json\" <<'JSON' |
54 | | -{ |
55 | | - \"plugins\": {} |
56 | | -} |
57 | | -JSON |
58 | | -fi |
59 | 51 | mkdir -p \"\$HOME/.openclaw/plugins\" |
60 | 52 | cat > \"\$HOME/.openclaw/plugins/installs.json\" <<'JSON' |
61 | 53 | { |
|
144 | 136 | |
145 | 137 | before_config_hash=\"\" |
146 | 138 | if [ \"\$OPENCLAW_PACKAGE_ACCEPTANCE_LEGACY_COMPAT\" != \"1\" ]; then |
147 | | - before_config_hash=\$(sha256sum \"\$HOME/.openclaw/openclaw.json\" | awk '{print \$1}') |
| 139 | + before_config_hash=\$(sha256sum \"\$OPENCLAW_CONFIG_PATH\" | awk '{print \$1}') |
148 | 140 | fi |
149 | 141 | |
150 | 142 | node --input-type=module > /tmp/plugin-update-before.json <<'NODE' |
|
182 | 174 | node \"\$entry\" plugins update @example/lossless-claw > /tmp/plugin-update-output.log 2>&1 |
183 | 175 | |
184 | 176 | if [ -n \"\$before_config_hash\" ]; then |
185 | | - after_config_hash=\$(sha256sum \"\$HOME/.openclaw/openclaw.json\" | awk '{print \$1}') |
| 177 | + after_config_hash=\$(sha256sum \"\$OPENCLAW_CONFIG_PATH\" | awk '{print \$1}') |
186 | 178 | if [ \"\$before_config_hash\" != \"\$after_config_hash\" ]; then |
187 | 179 | echo \"Config changed unexpectedly for modern package \$package_version\" |
188 | 180 | cat /tmp/plugin-update-output.log |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -6,7 +6,7 @@ const PLUGIN_UPDATE_DOCKER_SCRIPT = "scripts/e2e/plugin-update-unchanged-docker.
|
6 | 6 | describe("plugin update unchanged Docker E2E", () => { |
7 | 7 | it("seeds current plugin install ledger state before checking config stability", () => { |
8 | 8 | const script = readFileSync(PLUGIN_UPDATE_DOCKER_SCRIPT, "utf8"); |
9 | | -const configSeedStart = script.indexOf('cat > \\"\\$HOME/.openclaw/openclaw.json\\"'); |
| 9 | +const configSeedStart = script.indexOf('cat > \\"\\$OPENCLAW_CONFIG_PATH\\"'); |
10 | 10 | const configSeedEnd = script.indexOf('cat > \\"\\$HOME/.openclaw/plugins/installs.json\\"'); |
11 | 11 | const configSeed = script.slice(configSeedStart, configSeedEnd); |
12 | 12 | |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。