© 2026 Hedgehog Software, LLC
const layer = Logger.replace(Logger.defaultLogger, Custom.logger)
import { Runtime, FiberRefs } from "effect" const testableRuntime = Runtime.make({ context: Context.make(LoggingService, LoggingServiceLive).pipe( Context.add(EmailService, EmailServiceFake) ), fiberRefs: FiberRefs.empty(), runtimeFlags: Runtime.defaultRuntimeFlags })
const customRuntime = makeCustomRuntime() Effect.runSync(customRuntime) //or Effect.runPromise(customRuntime) // or const CustomRuntime = makeCustomRuntime() CustomRuntime.runPromise(program)
Effect.runPromise( Effect.provide(Logger.withMinimumLogLevel(program, LogLevel.Debug), layer) )
pipe( Effect.provide(layerWithCustomLogger), Effect.runPromise, )
const CustomRuntime = makeCustomRuntime() CustomRuntime.runPromise(program)