test: tighten minimax image endpoint assertion

This commit is contained in:
Peter Steinberger
2026-05-09 04:10:28 +01:00
parent 441e1b2930
commit 5720aa08d2

View File

@@ -47,7 +47,10 @@ describe("minimax image-generation provider", () => {
}
function expectImageGenerationUrl(fetchMock: ReturnType<typeof vi.fn>, url: string) {
expect(fetchMock).toHaveBeenCalledWith(url, expect.any(Object));
expect(fetchMock).toHaveBeenCalled();
const [actualUrl, init] = fetchMock.mock.calls[0] as [string, RequestInit | undefined];
expect(actualUrl).toBe(url);
expect(init?.method).toBe("POST");
}
it("generates PNG buffers through the shared provider HTTP path", async () => {