mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 07:40:44 +00:00
test: accept current codex status wording
This commit is contained in:
@@ -27,6 +27,16 @@ describe("gateway codex harness live helpers", () => {
|
||||
expect(isExpectedCodexStatusCommandText(text)).toBe(true);
|
||||
});
|
||||
|
||||
it("accepts current status prose that reports healthy session context without the session id", () => {
|
||||
const text = [
|
||||
"Status: running on `openai/gpt-5.5` with low reasoning/text settings.",
|
||||
"",
|
||||
"Session context is healthy: `22k/272k` tokens used, `0` compactions, `53%` cache hit. Current workspace is `/tmp/openclaw-live-codex-harness/workspace/dev`.",
|
||||
].join("\n");
|
||||
|
||||
expect(isExpectedCodexStatusCommandText(text)).toBe(true);
|
||||
});
|
||||
|
||||
it("accepts current app-server status prose without the OpenClaw prefix", () => {
|
||||
const text = [
|
||||
"Status: running on `openai/gpt-5.5` in `/tmp/openclaw-live-codex-harness/workspace/dev`.",
|
||||
|
||||
@@ -79,6 +79,7 @@ export const EXPECTED_CODEX_STATUS_COMMAND_TEXT = [
|
||||
"Session: agent:dev:live-codex-harness",
|
||||
"OpenClaw `",
|
||||
"OpenClaw status:",
|
||||
"Status: running on",
|
||||
"model `codex/",
|
||||
"session `agent:dev:live-codex-harness`",
|
||||
"Model/status card shown above",
|
||||
@@ -99,6 +100,7 @@ export function isExpectedCodexStatusCommandText(text: string): boolean {
|
||||
normalized.includes("session `agent:dev:live-codex-harness`") ||
|
||||
normalized.includes("current session is `agent:dev:live-codex-harness`") ||
|
||||
normalized.includes("current session is agent:dev:live-codex-harness") ||
|
||||
normalized.includes("session context is healthy") ||
|
||||
((normalized.includes("session context") || normalized.includes("context is at")) &&
|
||||
normalized.includes("active task: `/codex status`"));
|
||||
const mentionsModel =
|
||||
|
||||
Reference in New Issue
Block a user