Tests
All checks were successful
Lint / lint (push) Successful in 12s

This commit is contained in:
Julien Valverdé
2024-09-06 07:44:09 +02:00
parent 4e55a69937
commit e4975bafdf

18
src/Layers/trpc/tests.ts Normal file
View File

@@ -0,0 +1,18 @@
import { Console, Effect, identity } from "effect"
const expansiveComputation = Effect.gen(function*() {
yield* Console.log("executing")
return "value"
}).pipe(
Effect.cached,
)
await Effect.gen(function*() {
const cached = yield* expansiveComputation
yield* Console.log(yield* cached)
yield* Console.log(yield* cached)
yield* Console.log(yield* cached)
}).pipe(
Effect.runPromise
)