blob: 235b41b68ba9389a1e9ffb9548bfdd4b9f45c1a7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
export interface HttpExchangeFixture {
readonly request: {
readonly method: string;
readonly url: string;
readonly headers: Record<string, string>;
readonly body: string | null;
};
readonly response: {
readonly status: number;
readonly statusText?: string;
readonly headers: Record<string, string>;
readonly body: string;
};
readonly meta?: Record<string, string | number | boolean | null>;
}
export interface CapturedRequest {
method: string;
url: string;
headers: Record<string, string>;
body: string | null;
}
export type FetchLike = (input: string | URL | Request, init?: RequestInit) => Promise<Response>;
|