File tree Expand file tree Collapse file tree
platform/node/test/fixtures Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -107,7 +107,9 @@ export class PgContainer extends Context.Service<PgContainer>()("test/PgContaine
107107 // @effect -diagnostics-next-line promiseInEffectSuccess:off the promise is awaited below, outside the acquisition
108108 const starting = yield * Effect . acquireRelease (
109109 // @effect -diagnostics-next-line lazyPromiseInEffectSync:off
110- Effect . sync ( ( ) => new PostgreSqlContainer ( "postgres:alpine" ) . start ( ) ) ,
110+ Effect . sync ( ( ) =>
111+ new PostgreSqlContainer ( "postgres:alpine" ) . withCommand ( [ "postgres" , "-c" , "fsync=off" ] ) . start ( )
112+ ) ,
111113 releaseContainer
112114 )
113115 return yield * Effect . tryPromise ( {
Original file line number Diff line number Diff line change @@ -123,7 +123,12 @@ export class PgContainer extends Context.Service<PgContainer>()("test/PgContaine
123123 lifecycle (
124124 "new" ,
125125 "container-start" ,
126- ( ) => new PostgreSqlContainer ( "postgres:14-alpine" ) . withWaitStrategy ( pgWaitStrategy ( ) ) . start ( )
126+ ( ) =>
127+ new PostgreSqlContainer ( "postgres:14-alpine" )
128+ // Tests don't require crash durability; skip fsync waits during table setup.
129+ . withCommand ( [ "postgres" , "-c" , "fsync=off" ] )
130+ . withWaitStrategy ( pgWaitStrategy ( ) )
131+ . start ( )
127132 ) ,
128133 catch : ( cause ) => new ContainerError ( { cause } )
129134 } ) . pipe ( Effect . tap ( ( container ) => marker ( container . getId ( ) , "container-started" ) ) ) ,
You can’t perform that action at this time.
0 commit comments