test: pin the acp-agent.js exports of the v2 agent branch

Keeps isLoginRequiredText re-exported from acp-agent.js after its move to
result-end.ts, and adds the names the v2 agent imports from acp-agent.js
(AUTONOMOUS_RESULT_ORIGINS, getAvailableSlashCommands, isAbortedResult)
to the pinned list.

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Ben Brandt
2026-11-09 22:33:29 +01:00
parent 6db2e6ae20
commit c66464eace
2 changed files with 5 additions and 0 deletions

View File

@@ -464,6 +464,8 @@ export {
MODEL_CONFIG_ID,
resolveModelPreference,
} from "./session-model.js";
// Moved to result-end.ts; kept as an export for consumers that deep-import dist/acp-agent.js.
export { isLoginRequiredText } from "./result-end.js";
/** Claude CLI emits this synthetic result when an interrupted cycle ends on
* queued user input before producing any assistant content. It is a hand-off

View File

@@ -32,6 +32,7 @@ describe("module runtime exports", () => {
it("acp-agent.ts exports the expected names", async () => {
expect(Object.keys(await import("../acp-agent.js")).sort()).toEqual([
"AGENT_CONFIG_ID",
"AUTONOMOUS_RESULT_ORIGINS",
"BUILTIN_AGENT_NAMES",
"ClaudeAcpAgent",
"DEFAULT_AGENT_ID",
@@ -49,6 +50,8 @@ describe("module runtime exports", () => {
"createFastModeConfigOption",
"discoverCustomAgents",
"fastModeStateEnabled",
"getAvailableSlashCommands",
"isAbortedResult",
"isLocalCommandMetadata",
"isLoginRequiredText",
"isReplayHiddenMetaMessage",