mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-07 18:41:24 +00:00
perf(test): fold tool-policy + doctor workspace entrypoints
This commit is contained in:
@@ -1,13 +0,0 @@
|
||||
import { describe, expect, test } from "vitest";
|
||||
import { TOOL_POLICY_CONFORMANCE } from "./tool-policy.conformance.js";
|
||||
import { TOOL_GROUPS } from "./tool-policy.js";
|
||||
|
||||
describe("TOOL_POLICY_CONFORMANCE", () => {
|
||||
test("matches exported TOOL_GROUPS exactly", () => {
|
||||
expect(TOOL_POLICY_CONFORMANCE.toolGroups).toEqual(TOOL_GROUPS);
|
||||
});
|
||||
|
||||
test("is JSON-serializable", () => {
|
||||
expect(() => JSON.stringify(TOOL_POLICY_CONFORMANCE)).not.toThrow();
|
||||
});
|
||||
});
|
||||
@@ -1,4 +1,5 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import { TOOL_POLICY_CONFORMANCE } from "./tool-policy.conformance.js";
|
||||
import { expandToolGroups, resolveToolProfilePolicy, TOOL_GROUPS } from "./tool-policy.js";
|
||||
|
||||
describe("tool-policy", () => {
|
||||
@@ -28,3 +29,13 @@ describe("tool-policy", () => {
|
||||
expect(group).toContain("session_status");
|
||||
});
|
||||
});
|
||||
|
||||
describe("TOOL_POLICY_CONFORMANCE", () => {
|
||||
it("matches exported TOOL_GROUPS exactly", () => {
|
||||
expect(TOOL_POLICY_CONFORMANCE.toolGroups).toEqual(TOOL_GROUPS);
|
||||
});
|
||||
|
||||
it("is JSON-serializable", () => {
|
||||
expect(() => JSON.stringify(TOOL_POLICY_CONFORMANCE)).not.toThrow();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user