test: dedupe tokenjuice mock read

This commit is contained in:
Peter Steinberger
2026-05-13 07:02:06 +01:00
parent 53032505bd
commit 3945fd5812

View File

@@ -48,7 +48,7 @@ describe("tokenjuice bundled plugin", () => {
expect(createTokenjuiceOpenClawEmbeddedExtension).toHaveBeenCalledTimes(1);
expect(tokenjuiceFactory).toHaveBeenCalledTimes(1);
const registration = registerAgentToolResultMiddleware.mock.calls.at(0);
const registration = registerAgentToolResultMiddleware.mock.calls[0];
expect(typeof registration?.[0]).toBe("function");
expect(registration?.[1]).toEqual({ runtimes: ["pi", "codex"] });
});