Skip to content

Commit bb5ed5e

Browse files
test: isolate approval client e2e env
Co-authored-by: fuller-stack-dev <263060202+fuller-stack-dev@users.noreply.github.com>
1 parent b35d9cb commit bb5ed5e

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

src/gateway/operator-approvals-client.e2e.test.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,9 @@ const TEST_ENV_KEYS = [
1919
"HOME",
2020
"OPENCLAW_STATE_DIR",
2121
"OPENCLAW_CONFIG_PATH",
22+
"OPENCLAW_GATEWAY_URL",
2223
"OPENCLAW_GATEWAY_TOKEN",
24+
"OPENCLAW_GATEWAY_PASSWORD",
2325
"OPENCLAW_GATEWAY_PORT",
2426
];
2527

@@ -60,6 +62,10 @@ describe("operator approval gateway client runtime token source", () => {
6062
it("uses runtime authority only for generated local gateway URLs", async () => {
6163
const envSnapshot = captureEnv(TEST_ENV_KEYS);
6264
cleanup.push(() => envSnapshot.restore());
65+
delete process.env.OPENCLAW_CONFIG_PATH;
66+
delete process.env.OPENCLAW_GATEWAY_URL;
67+
delete process.env.OPENCLAW_GATEWAY_TOKEN;
68+
delete process.env.OPENCLAW_GATEWAY_PASSWORD;
6369

6470
const tempHome = await fs.mkdtemp(path.join(os.tmpdir(), "openclaw-approval-client-e2e-"));
6571
cleanup.push(() => fs.rm(tempHome, { recursive: true, force: true, maxRetries: 5 }));

0 commit comments

Comments
 (0)