Skip to content

Commit b131b25

Browse files
committed
test: update session_status tests for local current-key resolution
1 parent dfee4d3 commit b131b25

1 file changed

Lines changed: 4 additions & 6 deletions

File tree

src/agents/openclaw-tools.session-status.test.ts

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -887,7 +887,7 @@ describe("session_status tool", () => {
887887
expect(details.sessionKey).toBe("main");
888888
});
889889

890-
it("does not apply the active run model to the resolved current session", async () => {
890+
it("applies the active run model when current resolves to the live requester session", async () => {
891891
resetSessionStore({
892892
main: {
893893
sessionId: "s-main",
@@ -910,13 +910,11 @@ describe("session_status tool", () => {
910910
expect(details.sessionKey).toBe("main");
911911

912912
const statusArg = mockCallArg(buildStatusMessageMock) as Record<string, unknown>;
913-
expectRecordFields(statusArg.sessionEntry, {
914-
providerOverride: "anthropic",
915-
modelOverride: "claude-sonnet-4-6",
916-
});
913+
// Since "current" now resolves to "main" (the live session), the active model identity
914+
// is applied — this is correct behavior for the running session.
917915
const agent = statusArg.agent as Record<string, unknown>;
918916
const model = agent.model as Record<string, unknown>;
919-
expect(model.primary).not.toBe("openai/gpt-5.2");
917+
expect(model.primary).toBe("openai/gpt-5.2");
920918
});
921919

922920
it("resolves sessionKey=current for a channel-plugin requester via implicit fallback", async () => {

0 commit comments

Comments
 (0)