mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 09:00:42 +00:00
test: stabilize codex harness probes
This commit is contained in:
@@ -72,18 +72,15 @@
|
||||
},
|
||||
"approvalPolicy": {
|
||||
"type": "string",
|
||||
"enum": ["never", "on-request", "on-failure", "untrusted"],
|
||||
"default": "never"
|
||||
"enum": ["never", "on-request", "on-failure", "untrusted"]
|
||||
},
|
||||
"sandbox": {
|
||||
"type": "string",
|
||||
"enum": ["read-only", "workspace-write", "danger-full-access"],
|
||||
"default": "danger-full-access"
|
||||
"enum": ["read-only", "workspace-write", "danger-full-access"]
|
||||
},
|
||||
"approvalsReviewer": {
|
||||
"type": "string",
|
||||
"enum": ["user", "guardian_subagent"],
|
||||
"default": "user"
|
||||
"enum": ["user", "guardian_subagent"]
|
||||
},
|
||||
"serviceTier": { "type": ["string", "null"], "enum": ["fast", "flex", null] }
|
||||
}
|
||||
|
||||
@@ -214,4 +214,23 @@ describe("Codex app-server config", () => {
|
||||
expect(manifest.uiHints[`appServer.${key}`]).toBeTruthy();
|
||||
}
|
||||
});
|
||||
|
||||
it("does not schema-default mode-derived policy fields", async () => {
|
||||
const manifest = JSON.parse(
|
||||
await fs.readFile(new URL("../../openclaw.plugin.json", import.meta.url), "utf8"),
|
||||
) as {
|
||||
configSchema: {
|
||||
properties: {
|
||||
appServer: {
|
||||
properties: Record<string, { default?: unknown }>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
const appServerProperties = manifest.configSchema.properties.appServer.properties;
|
||||
|
||||
expect(appServerProperties.approvalPolicy?.default).toBeUndefined();
|
||||
expect(appServerProperties.sandbox?.default).toBeUndefined();
|
||||
expect(appServerProperties.approvalsReviewer?.default).toBeUndefined();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user