mirror of
https://github.com/anomalyco/opencode.git
synced 2026-07-24 17:53:37 +00:00
test(core): stabilize wellknown event subscriptions (#38331)
Co-authored-by: Aiden Cline <rekram1-node@users.noreply.github.com>
This commit is contained in:
parent
5a9ed4d350
commit
03474816ea
1 changed files with 2 additions and 2 deletions
|
|
@ -69,7 +69,7 @@ serviceIt.live("persists sources in one KV value", () =>
|
|||
const events = yield* EventV2.Service
|
||||
const changed = yield* events
|
||||
.subscribe(WellKnown.Event.Updated)
|
||||
.pipe(Stream.take(1), Stream.runCollect, Effect.forkScoped)
|
||||
.pipe(Stream.take(1), Stream.runCollect, Effect.forkScoped({ startImmediately: true }))
|
||||
const entry = yield* wellknown.add(`${server.url.origin}/`)
|
||||
|
||||
expect(entry.origin).toBe(server.url.origin)
|
||||
|
|
@ -108,7 +108,7 @@ serviceIt.live("refreshes changed manifests", () =>
|
|||
|
||||
const changed = yield* events
|
||||
.subscribe(WellKnown.Event.Updated)
|
||||
.pipe(Stream.take(1), Stream.runCollect, Effect.forkScoped)
|
||||
.pipe(Stream.take(1), Stream.runCollect, Effect.forkScoped({ startImmediately: true }))
|
||||
update()
|
||||
expect(yield* wellknown.refresh()).toBe(true)
|
||||
expect(yield* Fiber.join(changed)).toHaveLength(1)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue