@@ -272,6 +272,7 @@ describe("ClaudeAdapterLive", () => {
272272 } ) ;
273273
274274 const createInput = harness . getLastCreateQueryInput ( ) ;
275+ assert . deepEqual ( createInput ?. options . settingSources , [ "user" , "project" , "local" ] ) ;
275276 assert . equal ( createInput ?. options . permissionMode , "bypassPermissions" ) ;
276277 assert . equal ( createInput ?. options . allowDangerouslySkipPermissions , true ) ;
277278 } ) . pipe (
@@ -280,6 +281,26 @@ describe("ClaudeAdapterLive", () => {
280281 ) ;
281282 } ) ;
282283
284+ it . effect ( "loads Claude filesystem settings sources for SDK sessions" , ( ) => {
285+ const harness = makeHarness ( ) ;
286+ return Effect . gen ( function * ( ) {
287+ const adapter = yield * ClaudeAdapter ;
288+ yield * adapter . startSession ( {
289+ threadId : THREAD_ID ,
290+ provider : "claudeAgent" ,
291+ runtimeMode : "approval-required" ,
292+ } ) ;
293+
294+ const createInput = harness . getLastCreateQueryInput ( ) ;
295+ assert . deepEqual ( createInput ?. options . settingSources , [ "user" , "project" , "local" ] ) ;
296+ assert . equal ( createInput ?. options . permissionMode , undefined ) ;
297+ assert . equal ( createInput ?. options . allowDangerouslySkipPermissions , undefined ) ;
298+ } ) . pipe (
299+ Effect . provideService ( Random . Random , makeDeterministicRandomService ( ) ) ,
300+ Effect . provide ( harness . layer ) ,
301+ ) ;
302+ } ) ;
303+
283304 it . effect ( "keeps explicit claude permission mode over runtime-derived defaults" , ( ) => {
284305 const harness = makeHarness ( ) ;
285306 return Effect . gen ( function * ( ) {
0 commit comments