test(core): fix layer node replacement type expectation (#34386)

Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com>
Co-authored-by: opencode-agent[bot] <opencode-agent[bot]@users.noreply.github.com>
This commit is contained in:
opencode-agent[bot] 2026-06-29 00:03:02 -05:00 committed by GitHub
parent 846d548154
commit fb59606bb4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -69,10 +69,10 @@ void invalidNodeReplacement
// @ts-expect-error Replacement cannot introduce a new error
LayerNode.compile(a, [[a, Layer.effect(A, Effect.fail(new OtherError()))]])
const nodeReplacementWithError = make({ service: A, layer: Layer.effect(A, Effect.fail(new OtherError())), deps: [] })
// @ts-expect-error Node replacement cannot introduce a new error
const invalidNodeErrorReplacement = () =>
LayerNode.compile(a, [[a, make({ service: A, layer: Layer.effect(A, Effect.fail(new OtherError())), deps: [] })]])
void invalidNodeErrorReplacement
LayerNode.compile(a, [[a, nodeReplacementWithError]])
class TagA extends Context.Service<TagA, {}>()("test/TagA") {}
class TagB extends Context.Service<TagB, {}>()("test/TagB") {}