Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/soda/test/util.ts>mockFetch

SODA (Socrata) Client for Deno/Node
Latest
function mockFetch
import { mockFetch } from "https://deno.land/x/soda@0.4.5/test/util.ts";

Mock fetch() requests

Returns the provided response when a fetch() call's request matche the provided request object.

Parameters

request: Request
response: Response

Returns

Promise<void>