@@ -379,22 +379,6 @@ describe("ClaudeAdapterV2 runtime query policy", () => {
379379 );
380380 });
381381
382- it("a chosen workflow size overrides the one from launch arguments", () => {
383- const sentSize = (workflowSizeGuideline: ClaudeSettings["workflowSizeGuideline"]) =>
384- (
385- ClaudeAdapterV2.makeClaudeQueryOptions({
386- modelSelection: CLAUDE_TEST_MODEL_SELECTION,
387- nativeThreadId: "native-workflow-size",
388- resume: false,
389- cwd: "/workspace",
390- sdkSettings: { workflowSizeGuideline: "small" },
391- settings: { ...DEFAULT_CLAUDE_SETTINGS, workflowSizeGuideline },
392- }).settings as { workflowSizeGuideline?: string } | undefined
393- )?.workflowSizeGuideline;
394- assert.equal(sentSize("large"), "large");
395- assert.equal(sentSize("default"), "small");
396- });
397-
398382 it("projects AskUserQuestion input with question text as the answer key", () => {
399383 const preview = "\n **Proposed change**\n\n```ts\n\tconst enabled = true;\n```\n ";
400384 assert.deepEqual(
@@ -1063,12 +1047,16 @@ describe("ClaudeAdapterV2 Auto-accept edits", () => {
10631047});
10641048
10651049describe("ClaudeAdapterV2 append-system-prompt-file launch argument", () => {
1066- const startTurnWithLaunchArgs = Effect.fnUntraced(function* (launchArgs: string, cwd: string) {
1050+ const startTurnWithLaunchArgs = Effect.fnUntraced(function* (
1051+ launchArgs: string,
1052+ cwd: string,
1053+ settings?: Partial<ClaudeSettings>,
1054+ ) {
10671055 const fileSystem = yield* FileSystem.FileSystem;
10681056 const opened: Array<ClaudeAdapterV2.ClaudeAgentSdkQueryOptions> = [];
10691057 const adapter = yield* ClaudeAdapterV2.makeClaudeAdapterV2({
10701058 instanceId: ClaudeAdapterV2.CLAUDE_DEFAULT_INSTANCE_ID,
1071- settings: { ...DEFAULT_CLAUDE_SETTINGS, launchArgs },
1059+ settings: { ...DEFAULT_CLAUDE_SETTINGS, ...settings, launchArgs },
10721060 environment: {},
10731061 attachmentsDir: yield* fileSystem.makeTempDirectoryScoped({ prefix: "t3-claude-append-" }),
10741062 fileSystem,
@@ -1172,7 +1160,7 @@ describe("ClaudeAdapterV2 append-system-prompt-file launch argument", () => {
11721160
11731161 // regression: #15073 the SDK replaced the --settings launch argument with T3's settings
11741162 it.effect.each([
1175- `--settings '{"skillOverrides":{"lint":"off"},"showThinkingSummaries":false}'`,
1163+ `--settings '{"skillOverrides":{"lint":"off"},"showThinkingSummaries":false,"workflowSizeGuideline":"small" }'`,
11761164 "--settings user-settings.json",
11771165 ])("merges %s beneath T3's settings", (launchArgs) =>
11781166 Effect.scoped(
@@ -1181,15 +1169,20 @@ describe("ClaudeAdapterV2 append-system-prompt-file launch argument", () => {
11811169 const cwd = yield* fileSystem.makeTempDirectoryScoped({ prefix: "t3-claude-settings-" });
11821170 yield* fileSystem.writeFileString(
11831171 NodePath.join(cwd, "user-settings.json"),
1184- '{"skillOverrides":{"lint":"off"},"showThinkingSummaries":false}',
1172+ '{"skillOverrides":{"lint":"off"},"showThinkingSummaries":false,"workflowSizeGuideline":"small" }',
11851173 );
11861174 const { exit, opened } = yield* startTurnWithLaunchArgs(launchArgs, cwd);
11871175 assert.isTrue(Exit.isSuccess(exit));
11881176 assert.deepInclude(opened[0]!.settings, {
11891177 skillOverrides: { lint: "off" },
11901178 showThinkingSummaries: true,
1179+ workflowSizeGuideline: "small",
11911180 });
11921181 assert.isUndefined(opened[0]!.extraArgs?.["settings"]);
1182+ const chosen = yield* startTurnWithLaunchArgs(launchArgs, cwd, {
1183+ workflowSizeGuideline: "large",
1184+ });
1185+ assert.deepInclude(chosen.opened[0]!.settings, { workflowSizeGuideline: "large" });
11931186 }).pipe(
11941187 Effect.provide(
11951188 Layer.mergeAll(
0 commit comments