mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-04 02:00:21 +00:00
perf(cli): reduce read-only startup overhead
This commit is contained in:
@@ -144,6 +144,10 @@ describe("argv helpers", () => {
|
||||
expect(shouldMigrateState(["node", "openclaw", "status"])).toBe(false);
|
||||
expect(shouldMigrateState(["node", "openclaw", "health"])).toBe(false);
|
||||
expect(shouldMigrateState(["node", "openclaw", "sessions"])).toBe(false);
|
||||
expect(shouldMigrateState(["node", "openclaw", "config", "get", "update"])).toBe(false);
|
||||
expect(shouldMigrateState(["node", "openclaw", "config", "unset", "update"])).toBe(false);
|
||||
expect(shouldMigrateState(["node", "openclaw", "models", "list"])).toBe(false);
|
||||
expect(shouldMigrateState(["node", "openclaw", "models", "status"])).toBe(false);
|
||||
expect(shouldMigrateState(["node", "openclaw", "memory", "status"])).toBe(false);
|
||||
expect(shouldMigrateState(["node", "openclaw", "agent", "--message", "hi"])).toBe(false);
|
||||
expect(shouldMigrateState(["node", "openclaw", "agents", "list"])).toBe(true);
|
||||
@@ -152,6 +156,8 @@ describe("argv helpers", () => {
|
||||
|
||||
it("reuses command path for migrate state decisions", () => {
|
||||
expect(shouldMigrateStateFromPath(["status"])).toBe(false);
|
||||
expect(shouldMigrateStateFromPath(["config", "get"])).toBe(false);
|
||||
expect(shouldMigrateStateFromPath(["models", "status"])).toBe(false);
|
||||
expect(shouldMigrateStateFromPath(["agents", "list"])).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user