diff --git a/src/security/audit.test.ts b/src/security/audit.test.ts index 449fe82045c..abbdf905b0f 100644 --- a/src/security/audit.test.ts +++ b/src/security/audit.test.ts @@ -3639,4 +3639,27 @@ description: test skill expect(warning?.detail).toContain("gateway.auth.token"); }); }); + + it("identifies claude-opus-4-6 as a strong model (>= 4.5)", async () => { + const cfg: OpenClawConfig = { + agents: { + defaults: { + model: { + primary: "anthropic/claude-opus-4-6", + }, + }, + }, + }; + + const res = await runSecurityAudit({ + config: cfg, + includeFilesystem: false, + includeChannelSecurity: false, + }); + + const weakFinding = res.findings.find( + (f) => f.checkId === "models.hygiene" && f.detail.includes("Below Claude 4.5"), + ); + expect(weakFinding).toBeUndefined(); + }); });