fix(coding-agent): update end-of-options CLI test

This commit is contained in:
Armin Ronacher 2026-08-23 12:39:20 +02:00
parent c1279a65b3
commit bcad846f93

View file

@ -92,11 +92,13 @@ describe("experimental CLI commands", () => {
const result = experimentalCli.parse(["--unknown", "@prompt.md", "--", "--listen", "unix:///tmp/pi.sock"]);
expect(result).toMatchObject({
ok: true,
command: { command: "pi", options: { fileArgs: ["prompt.md"] } },
command: {
command: "pi",
options: { fileArgs: ["prompt.md"], messages: ["--listen", "unix:///tmp/pi.sock"] },
},
});
if (!result.ok || result.command.command !== "pi") return;
expect(result.command.options.unknownFlags.get("unknown")).toBe(true);
expect(result.command.options.unknownFlags.get("listen")).toBe("unix:///tmp/pi.sock");
expect(result.command.options.unknownFlags).toEqual(new Map([["unknown", true]]));
});
test.each([