mirror of
https://github.com/anomalyco/opencode.git
synced 2026-08-15 05:33:30 +00:00
chore: generate
This commit is contained in:
parent
1d4613006a
commit
e46ab34d27
4 changed files with 19 additions and 12 deletions
|
|
@ -220,17 +220,19 @@ describe("InstanceStore", () => {
|
|||
}),
|
||||
)
|
||||
|
||||
it.instance("provides legacy Promise callers with instance ALS", () =>
|
||||
Effect.gen(function* () {
|
||||
const test = yield* TestInstance
|
||||
const ctx = yield* InstanceRef
|
||||
if (!ctx) throw new Error("InstanceRef not provided")
|
||||
it.instance(
|
||||
"provides legacy Promise callers with instance ALS",
|
||||
() =>
|
||||
Effect.gen(function* () {
|
||||
const test = yield* TestInstance
|
||||
const ctx = yield* InstanceRef
|
||||
if (!ctx) throw new Error("InstanceRef not provided")
|
||||
|
||||
const directory = yield* Effect.promise(() => Promise.resolve(Instance.restore(ctx, () => Instance.directory)))
|
||||
const directory = yield* Effect.promise(() => Promise.resolve(Instance.restore(ctx, () => Instance.directory)))
|
||||
|
||||
expect(directory).toBe(test.directory)
|
||||
expect(() => Instance.current).toThrow()
|
||||
}),
|
||||
expect(directory).toBe(test.directory)
|
||||
expect(() => Instance.current).toThrow()
|
||||
}),
|
||||
{ git: true },
|
||||
)
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue