test(codemode): drop leftover $codemode references (#36451)
This commit is contained in:
parent
b9f39dd751
commit
75e8fd4da2
3 changed files with 10 additions and 23 deletions
|
|
@ -761,11 +761,6 @@ describe("CodeMode public contract", () => {
|
|||
"tools.thread.generateImage",
|
||||
)
|
||||
}
|
||||
|
||||
// The retired $codemode namespace is gone from the tools tree entirely.
|
||||
const removed = await Effect.runPromise(runtime.execute(`return await tools.$codemode.search({ query: "file" })`))
|
||||
expect(removed.ok).toBe(false)
|
||||
if (!removed.ok) expect(removed.error.kind).toBe("UnknownTool")
|
||||
})
|
||||
|
||||
test("search is a counted tool call: it burns maxToolCalls and fires the hooks", async () => {
|
||||
|
|
@ -1195,11 +1190,4 @@ describe("CodeMode public contract", () => {
|
|||
}
|
||||
expect(elapsedMs).toBeLessThan(3_000)
|
||||
})
|
||||
|
||||
test("a host $codemode namespace is an ordinary namespace now that search is a built-in", async () => {
|
||||
const runtime = CodeMode.make({ tools: { $codemode: { lookup } } })
|
||||
const result = await Effect.runPromise(runtime.execute(`return await tools.$codemode.lookup({ id: "order_1" })`))
|
||||
expect(result.ok).toBe(true)
|
||||
if (result.ok) expect(result.value).toStrictEqual({ id: "order_1", status: "open" })
|
||||
})
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue