mirror of https://github.com/openclaw/openclaw.git
test: restore fetch stubs in embedding suites
This commit is contained in:
parent
101c31f5e1
commit
78b48735fa
|
|
@ -44,7 +44,7 @@ const createGeminiBatchFetchMock = (count: number, embeddingValues = [1, 2, 3])
|
|||
}));
|
||||
|
||||
function installFetchMock(fetchMock: typeof globalThis.fetch) {
|
||||
globalThis.fetch = fetchMock;
|
||||
vi.stubGlobal("fetch", fetchMock);
|
||||
}
|
||||
|
||||
function readFirstFetchRequest(fetchMock: { mock: { calls: unknown[][] } }) {
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ const createFetchMock = () => {
|
|||
};
|
||||
|
||||
function installFetchMock(fetchMock: typeof globalThis.fetch) {
|
||||
globalThis.fetch = fetchMock;
|
||||
vi.stubGlobal("fetch", fetchMock);
|
||||
}
|
||||
|
||||
let authModule: typeof import("../../../../src/agents/model-auth.js");
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ const createGeminiFetchMock = () =>
|
|||
}));
|
||||
|
||||
function installFetchMock(fetchMock: typeof globalThis.fetch) {
|
||||
globalThis.fetch = fetchMock;
|
||||
vi.stubGlobal("fetch", fetchMock);
|
||||
}
|
||||
|
||||
function readFirstFetchRequest(fetchMock: { mock: { calls: unknown[][] } }) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue