@schmock/core 2.3.0 → 2.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +35 -0
- package/dist/abort.d.ts +3 -0
- package/dist/abort.d.ts.map +1 -0
- package/dist/abort.js +30 -0
- package/dist/builder.d.ts +31 -10
- package/dist/builder.d.ts.map +1 -1
- package/dist/builder.js +760 -190
- package/dist/constants.d.ts +38 -0
- package/dist/constants.d.ts.map +1 -1
- package/dist/constants.js +123 -2
- package/dist/errors.d.ts +14 -3
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +41 -6
- package/dist/helpers.d.ts +9 -0
- package/dist/helpers.d.ts.map +1 -1
- package/dist/helpers.js +18 -2
- package/dist/http-helpers.d.ts +39 -4
- package/dist/http-helpers.d.ts.map +1 -1
- package/dist/http-helpers.js +147 -49
- package/dist/index.d.ts +292 -34
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -3
- package/dist/interceptor.d.ts +11 -1
- package/dist/interceptor.d.ts.map +1 -1
- package/dist/interceptor.js +316 -169
- package/dist/parser.d.ts.map +1 -1
- package/dist/parser.js +12 -3
- package/dist/plugin-pipeline.d.ts +3 -3
- package/dist/plugin-pipeline.d.ts.map +1 -1
- package/dist/plugin-pipeline.js +29 -14
- package/dist/response-normalizer.d.ts +16 -0
- package/dist/response-normalizer.d.ts.map +1 -0
- package/dist/response-normalizer.js +316 -0
- package/dist/response-parser.d.ts.map +1 -1
- package/dist/response-parser.js +39 -2
- package/dist/route-matcher.d.ts +3 -0
- package/dist/route-matcher.d.ts.map +1 -1
- package/dist/route-matcher.js +12 -6
- package/dist/types.d.ts +7 -2
- package/dist/types.d.ts.map +1 -1
- package/package.json +18 -6
- package/src/audit-core-builder.test.ts +0 -218
- package/src/audit-response-guard.test.ts +0 -38
- package/src/binary.test.ts +0 -126
- package/src/binary.ts +0 -11
- package/src/builder.test.ts +0 -289
- package/src/builder.ts +0 -748
- package/src/constants.test.ts +0 -99
- package/src/constants.ts +0 -73
- package/src/debug.test.ts +0 -241
- package/src/delay.test.ts +0 -319
- package/src/dist-shape.test.ts +0 -35
- package/src/errors.test.ts +0 -223
- package/src/errors.ts +0 -130
- package/src/factory.test.ts +0 -133
- package/src/helpers.test.ts +0 -147
- package/src/helpers.ts +0 -58
- package/src/http-helpers.test.ts +0 -39
- package/src/http-helpers.ts +0 -149
- package/src/index.ts +0 -152
- package/src/interceptor.test.ts +0 -488
- package/src/interceptor.ts +0 -407
- package/src/namespace.test.ts +0 -274
- package/src/parser.property.test.ts +0 -630
- package/src/parser.test.ts +0 -148
- package/src/parser.ts +0 -64
- package/src/plugin-pipeline.ts +0 -208
- package/src/plugin-system.test.ts +0 -697
- package/src/response-parser.ts +0 -114
- package/src/response-parsing.test.ts +0 -333
- package/src/route-matcher.ts +0 -69
- package/src/route-matching.test.ts +0 -394
- package/src/server.test.ts +0 -234
- package/src/smart-defaults.test.ts +0 -361
- package/src/steps/async-support.steps.ts +0 -421
- package/src/steps/audit-core-builder.steps.ts +0 -188
- package/src/steps/audit-onerror-tuple.steps.ts +0 -83
- package/src/steps/basic-usage.steps.ts +0 -245
- package/src/steps/developer-experience.steps.ts +0 -204
- package/src/steps/error-handling.steps.ts +0 -555
- package/src/steps/fetch-interceptor.steps.ts +0 -457
- package/src/steps/fluent-api.steps.ts +0 -255
- package/src/steps/http-methods.steps.ts +0 -342
- package/src/steps/lifecycle-events.steps.ts +0 -149
- package/src/steps/performance-reliability.steps.ts +0 -90
- package/src/steps/plugin-integration.steps.ts +0 -334
- package/src/steps/request-history.steps.ts +0 -458
- package/src/steps/response-delay.steps.ts +0 -88
- package/src/steps/route-key-format.steps.ts +0 -99
- package/src/steps/standalone-server.steps.ts +0 -227
- package/src/steps/state-concurrency.steps.ts +0 -167
- package/src/types.ts +0 -36
|
@@ -1,227 +0,0 @@
|
|
|
1
|
-
import { describeFeature, loadFeature } from "@amiceli/vitest-cucumber";
|
|
2
|
-
import { expect } from "vitest";
|
|
3
|
-
import { schmock } from "../index";
|
|
4
|
-
|
|
5
|
-
const feature = await loadFeature("../../features/standalone-server.feature");
|
|
6
|
-
|
|
7
|
-
describeFeature(feature, ({ Scenario, AfterEachScenario }) => {
|
|
8
|
-
let mock: Schmock.CallableMockInstance;
|
|
9
|
-
let serverInfo: Schmock.ServerInfo;
|
|
10
|
-
let httpResponse: Response;
|
|
11
|
-
|
|
12
|
-
AfterEachScenario(() => {
|
|
13
|
-
mock?.close();
|
|
14
|
-
});
|
|
15
|
-
|
|
16
|
-
function baseUrl(): string {
|
|
17
|
-
return `http://${serverInfo.hostname}:${serverInfo.port}`;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
Scenario("Start and stop a simple server", ({ Given, When, Then, And }) => {
|
|
21
|
-
Given("I create a mock with a GET /hello route", () => {
|
|
22
|
-
mock = schmock();
|
|
23
|
-
mock("GET /hello", { message: "hello" });
|
|
24
|
-
});
|
|
25
|
-
|
|
26
|
-
When("I start the server on a random port", async () => {
|
|
27
|
-
serverInfo = await mock.listen(0);
|
|
28
|
-
});
|
|
29
|
-
|
|
30
|
-
Then("the server should be running", () => {
|
|
31
|
-
expect(serverInfo.port).toBeGreaterThan(0);
|
|
32
|
-
});
|
|
33
|
-
|
|
34
|
-
When("I fetch {string} from the server", async (_, route: string) => {
|
|
35
|
-
const [, path] = route.split(" ");
|
|
36
|
-
httpResponse = await fetch(`${baseUrl()}${path}`);
|
|
37
|
-
});
|
|
38
|
-
|
|
39
|
-
Then("the HTTP response status should be {int}", (_, status: number) => {
|
|
40
|
-
expect(httpResponse.status).toBe(status);
|
|
41
|
-
});
|
|
42
|
-
|
|
43
|
-
And(
|
|
44
|
-
"the HTTP response body should have {string} equal to {string}",
|
|
45
|
-
async (_, key: string, value: string) => {
|
|
46
|
-
const body = await httpResponse.json();
|
|
47
|
-
expect(body[key]).toBe(value);
|
|
48
|
-
},
|
|
49
|
-
);
|
|
50
|
-
|
|
51
|
-
When("I stop the server", () => {
|
|
52
|
-
mock.close();
|
|
53
|
-
});
|
|
54
|
-
|
|
55
|
-
Then("the server should not be running", async () => {
|
|
56
|
-
await expect(fetch(`${baseUrl()}/hello`)).rejects.toBeDefined();
|
|
57
|
-
});
|
|
58
|
-
});
|
|
59
|
-
|
|
60
|
-
Scenario("Handle POST with JSON body", ({ Given, When, Then, And }) => {
|
|
61
|
-
Given("I create a mock echoing POST at {string}", (_, path: string) => {
|
|
62
|
-
mock = schmock();
|
|
63
|
-
mock(`POST ${path}`, ({ body }) => body);
|
|
64
|
-
});
|
|
65
|
-
|
|
66
|
-
When("I start the server on a random port", async () => {
|
|
67
|
-
serverInfo = await mock.listen(0);
|
|
68
|
-
});
|
|
69
|
-
|
|
70
|
-
And(
|
|
71
|
-
"I fetch {string} with JSON body:",
|
|
72
|
-
async (_, route: string, docString: string) => {
|
|
73
|
-
const [method, path] = route.split(" ");
|
|
74
|
-
httpResponse = await fetch(`${baseUrl()}${path}`, {
|
|
75
|
-
method,
|
|
76
|
-
headers: { "content-type": "application/json" },
|
|
77
|
-
body: docString,
|
|
78
|
-
});
|
|
79
|
-
},
|
|
80
|
-
);
|
|
81
|
-
|
|
82
|
-
Then(
|
|
83
|
-
"the response status from POST should be {int}",
|
|
84
|
-
(_, status: number) => {
|
|
85
|
-
expect(httpResponse.status).toBe(status);
|
|
86
|
-
},
|
|
87
|
-
);
|
|
88
|
-
|
|
89
|
-
And(
|
|
90
|
-
"the response body from POST should have {string} equal to {string}",
|
|
91
|
-
async (_, key: string, value: string) => {
|
|
92
|
-
const body = await httpResponse.json();
|
|
93
|
-
expect(body[key]).toBe(value);
|
|
94
|
-
},
|
|
95
|
-
);
|
|
96
|
-
|
|
97
|
-
When("I stop the server", () => {
|
|
98
|
-
mock.close();
|
|
99
|
-
});
|
|
100
|
-
});
|
|
101
|
-
|
|
102
|
-
Scenario(
|
|
103
|
-
"Return 404 for unregistered routes",
|
|
104
|
-
({ Given, When, And, Then }) => {
|
|
105
|
-
Given("I create a mock with a GET /hello route", () => {
|
|
106
|
-
mock = schmock();
|
|
107
|
-
mock("GET /hello", { message: "hello" });
|
|
108
|
-
});
|
|
109
|
-
|
|
110
|
-
When("I start the server on a random port", async () => {
|
|
111
|
-
serverInfo = await mock.listen(0);
|
|
112
|
-
});
|
|
113
|
-
|
|
114
|
-
And("I fetch {string} from the server", async (_, route: string) => {
|
|
115
|
-
const [, path] = route.split(" ");
|
|
116
|
-
httpResponse = await fetch(`${baseUrl()}${path}`);
|
|
117
|
-
});
|
|
118
|
-
|
|
119
|
-
Then("the HTTP response status should be {int}", (_, status: number) => {
|
|
120
|
-
expect(httpResponse.status).toBe(status);
|
|
121
|
-
});
|
|
122
|
-
|
|
123
|
-
When("I stop the server", () => {
|
|
124
|
-
mock.close();
|
|
125
|
-
});
|
|
126
|
-
},
|
|
127
|
-
);
|
|
128
|
-
|
|
129
|
-
Scenario("Query parameters are forwarded", ({ Given, When, And, Then }) => {
|
|
130
|
-
let parsedBody: Record<string, string>;
|
|
131
|
-
|
|
132
|
-
Given(
|
|
133
|
-
"I create a mock reflecting query params at {string}",
|
|
134
|
-
(_, route: string) => {
|
|
135
|
-
const [method, path] = route.split(" ");
|
|
136
|
-
mock = schmock();
|
|
137
|
-
mock(`${method} ${path}` as Schmock.RouteKey, ({ query }) => query);
|
|
138
|
-
},
|
|
139
|
-
);
|
|
140
|
-
|
|
141
|
-
When("I start the server on a random port", async () => {
|
|
142
|
-
serverInfo = await mock.listen(0);
|
|
143
|
-
});
|
|
144
|
-
|
|
145
|
-
And("I fetch {string} from the server", async (_, route: string) => {
|
|
146
|
-
const [, pathWithQuery] = route.split(" ");
|
|
147
|
-
httpResponse = await fetch(`${baseUrl()}${pathWithQuery}`);
|
|
148
|
-
parsedBody = await httpResponse.json();
|
|
149
|
-
});
|
|
150
|
-
|
|
151
|
-
Then("the HTTP response status should be {int}", (_, status: number) => {
|
|
152
|
-
expect(httpResponse.status).toBe(status);
|
|
153
|
-
});
|
|
154
|
-
|
|
155
|
-
And(
|
|
156
|
-
"the HTTP response body should have {string} equal to {string}",
|
|
157
|
-
(_, key: string, value: string) => {
|
|
158
|
-
expect(parsedBody[key]).toBe(value);
|
|
159
|
-
},
|
|
160
|
-
);
|
|
161
|
-
|
|
162
|
-
And(
|
|
163
|
-
"the query param {string} should equal {string}",
|
|
164
|
-
(_, key: string, value: string) => {
|
|
165
|
-
expect(parsedBody[key]).toBe(value);
|
|
166
|
-
},
|
|
167
|
-
);
|
|
168
|
-
|
|
169
|
-
When("I stop the server", () => {
|
|
170
|
-
mock.close();
|
|
171
|
-
});
|
|
172
|
-
});
|
|
173
|
-
|
|
174
|
-
Scenario("Double listen throws an error", ({ Given, When, Then }) => {
|
|
175
|
-
Given("I create a mock with a GET /hello route", () => {
|
|
176
|
-
mock = schmock();
|
|
177
|
-
mock("GET /hello", { message: "hello" });
|
|
178
|
-
});
|
|
179
|
-
|
|
180
|
-
When("I start the server on a random port", async () => {
|
|
181
|
-
serverInfo = await mock.listen(0);
|
|
182
|
-
});
|
|
183
|
-
|
|
184
|
-
Then("starting the server again should throw", () => {
|
|
185
|
-
expect(() => mock.listen(0)).toThrow("Server is already running");
|
|
186
|
-
mock.close();
|
|
187
|
-
});
|
|
188
|
-
});
|
|
189
|
-
|
|
190
|
-
Scenario("Close is idempotent", ({ Given, When, And, Then }) => {
|
|
191
|
-
Given("I create a mock with a GET /hello route", () => {
|
|
192
|
-
mock = schmock();
|
|
193
|
-
mock("GET /hello", { message: "hello" });
|
|
194
|
-
});
|
|
195
|
-
|
|
196
|
-
When("I start the server on a random port", async () => {
|
|
197
|
-
serverInfo = await mock.listen(0);
|
|
198
|
-
});
|
|
199
|
-
|
|
200
|
-
And("I stop the server", () => {
|
|
201
|
-
mock.close();
|
|
202
|
-
});
|
|
203
|
-
|
|
204
|
-
Then("stopping the server again should not throw", () => {
|
|
205
|
-
expect(() => mock.close()).not.toThrow();
|
|
206
|
-
});
|
|
207
|
-
});
|
|
208
|
-
|
|
209
|
-
Scenario("Reset stops the server", ({ Given, When, And, Then }) => {
|
|
210
|
-
Given("I create a mock with a GET /hello route", () => {
|
|
211
|
-
mock = schmock();
|
|
212
|
-
mock("GET /hello", { message: "hello" });
|
|
213
|
-
});
|
|
214
|
-
|
|
215
|
-
When("I start the server on a random port", async () => {
|
|
216
|
-
serverInfo = await mock.listen(0);
|
|
217
|
-
});
|
|
218
|
-
|
|
219
|
-
And("I reset the mock", () => {
|
|
220
|
-
mock.reset();
|
|
221
|
-
});
|
|
222
|
-
|
|
223
|
-
Then("the server should not be running", async () => {
|
|
224
|
-
await expect(fetch(`${baseUrl()}/hello`)).rejects.toBeDefined();
|
|
225
|
-
});
|
|
226
|
-
});
|
|
227
|
-
});
|
|
@@ -1,167 +0,0 @@
|
|
|
1
|
-
import { describeFeature, loadFeature } from "@amiceli/vitest-cucumber";
|
|
2
|
-
import { expect } from "vitest";
|
|
3
|
-
import { schmock } from "../index";
|
|
4
|
-
|
|
5
|
-
const feature = await loadFeature("../../features/state-concurrency.feature");
|
|
6
|
-
|
|
7
|
-
function readCounter(state: Record<string, unknown>): number {
|
|
8
|
-
const counter = state.counter;
|
|
9
|
-
if (typeof counter !== "number") throw new Error("Counter state is invalid");
|
|
10
|
-
return counter;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
function isRecord(value: unknown): value is Record<string, unknown> {
|
|
14
|
-
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
function responseRecord(response: Schmock.Response): Record<string, unknown> {
|
|
18
|
-
if (!isRecord(response.body)) {
|
|
19
|
-
throw new Error("Expected an object response");
|
|
20
|
-
}
|
|
21
|
-
return response.body;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
function withTimeout(
|
|
25
|
-
promise: Promise<void>,
|
|
26
|
-
timeoutMs: number,
|
|
27
|
-
message: string,
|
|
28
|
-
): Promise<void> {
|
|
29
|
-
let timeoutId: ReturnType<typeof setTimeout> | undefined;
|
|
30
|
-
const timeout = new Promise<never>((_, reject) => {
|
|
31
|
-
timeoutId = setTimeout(() => reject(new Error(message)), timeoutMs);
|
|
32
|
-
});
|
|
33
|
-
|
|
34
|
-
return Promise.race([promise, timeout]).finally(() => {
|
|
35
|
-
if (timeoutId !== undefined) clearTimeout(timeoutId);
|
|
36
|
-
});
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
describeFeature(feature, ({ Scenario }) => {
|
|
40
|
-
let firstMock: Schmock.CallableMockInstance;
|
|
41
|
-
let secondMock: Schmock.CallableMockInstance;
|
|
42
|
-
let firstResponse: Schmock.Response;
|
|
43
|
-
let secondResponse: Schmock.Response;
|
|
44
|
-
let concurrentResponses: Schmock.Response[] = [];
|
|
45
|
-
let expectedConcurrentCount = 0;
|
|
46
|
-
|
|
47
|
-
Scenario(
|
|
48
|
-
"Different mock instances keep independent route state",
|
|
49
|
-
({ Given, When, Then, And }) => {
|
|
50
|
-
Given("I create two mocks with different counter state", () => {
|
|
51
|
-
firstMock = schmock({ state: { counter: 0 } });
|
|
52
|
-
secondMock = schmock({ state: { counter: 100 } });
|
|
53
|
-
|
|
54
|
-
const registerIncrement = (mock: Schmock.CallableMockInstance) => {
|
|
55
|
-
mock("POST /increment", ({ state }) => {
|
|
56
|
-
const next = readCounter(state) + 1;
|
|
57
|
-
state.counter = next;
|
|
58
|
-
return { counter: next };
|
|
59
|
-
});
|
|
60
|
-
};
|
|
61
|
-
registerIncrement(firstMock);
|
|
62
|
-
registerIncrement(secondMock);
|
|
63
|
-
});
|
|
64
|
-
|
|
65
|
-
When("I increment both mocks concurrently", async () => {
|
|
66
|
-
[firstResponse, secondResponse] = await Promise.all([
|
|
67
|
-
firstMock.handle("POST", "/increment"),
|
|
68
|
-
secondMock.handle("POST", "/increment"),
|
|
69
|
-
]);
|
|
70
|
-
});
|
|
71
|
-
|
|
72
|
-
Then("the first mock counter should be {int}", (_, counter: number) => {
|
|
73
|
-
expect(responseRecord(firstResponse).counter).toBe(counter);
|
|
74
|
-
expect(firstMock.getState().counter).toBe(counter);
|
|
75
|
-
});
|
|
76
|
-
|
|
77
|
-
And("the second mock counter should be {int}", (_, counter: number) => {
|
|
78
|
-
expect(responseRecord(secondResponse).counter).toBe(counter);
|
|
79
|
-
expect(secondMock.getState().counter).toBe(counter);
|
|
80
|
-
});
|
|
81
|
-
},
|
|
82
|
-
);
|
|
83
|
-
|
|
84
|
-
Scenario(
|
|
85
|
-
"Concurrent requests keep plugin state isolated",
|
|
86
|
-
({ Given, When, Then }) => {
|
|
87
|
-
let requestCount = 0;
|
|
88
|
-
let arrivals = 0;
|
|
89
|
-
let boundedBarrier: Promise<void> | undefined;
|
|
90
|
-
let releaseBarrier: (() => void) | undefined;
|
|
91
|
-
|
|
92
|
-
Given(
|
|
93
|
-
"I create a two-stage plugin pipeline with a shared async barrier",
|
|
94
|
-
() => {
|
|
95
|
-
arrivals = 0;
|
|
96
|
-
|
|
97
|
-
const firstStage: Schmock.Plugin = {
|
|
98
|
-
name: "first-stage",
|
|
99
|
-
async process(context, response) {
|
|
100
|
-
context.state.set("request-id", context.params.id);
|
|
101
|
-
arrivals += 1;
|
|
102
|
-
if (arrivals === requestCount) releaseBarrier?.();
|
|
103
|
-
if (!boundedBarrier) {
|
|
104
|
-
throw new Error("Plugin rendezvous was not initialized");
|
|
105
|
-
}
|
|
106
|
-
await boundedBarrier;
|
|
107
|
-
return { context, response };
|
|
108
|
-
},
|
|
109
|
-
};
|
|
110
|
-
const secondStage: Schmock.Plugin = {
|
|
111
|
-
name: "second-stage",
|
|
112
|
-
process(context, response) {
|
|
113
|
-
const firstStageId = context.state.get("request-id");
|
|
114
|
-
return {
|
|
115
|
-
context,
|
|
116
|
-
response: {
|
|
117
|
-
routeId: context.params.id,
|
|
118
|
-
firstStageId,
|
|
119
|
-
original: response,
|
|
120
|
-
},
|
|
121
|
-
};
|
|
122
|
-
},
|
|
123
|
-
};
|
|
124
|
-
|
|
125
|
-
firstMock = schmock();
|
|
126
|
-
firstMock("GET /work/:id", ({ params }) => ({ id: params.id }))
|
|
127
|
-
.pipe(firstStage)
|
|
128
|
-
.pipe(secondStage);
|
|
129
|
-
},
|
|
130
|
-
);
|
|
131
|
-
|
|
132
|
-
When(
|
|
133
|
-
"I issue {int} concurrent requests with distinct IDs through the pipeline",
|
|
134
|
-
async (_scenario, count: number) => {
|
|
135
|
-
requestCount = count;
|
|
136
|
-
expectedConcurrentCount = count;
|
|
137
|
-
const barrier = new Promise<void>((resolve) => {
|
|
138
|
-
releaseBarrier = resolve;
|
|
139
|
-
});
|
|
140
|
-
boundedBarrier = withTimeout(
|
|
141
|
-
barrier,
|
|
142
|
-
2_000,
|
|
143
|
-
`Timed out waiting for ${count} requests to reach the plugin rendezvous`,
|
|
144
|
-
);
|
|
145
|
-
concurrentResponses = await Promise.all(
|
|
146
|
-
Array.from({ length: count }, (_, index) =>
|
|
147
|
-
firstMock.handle("GET", `/work/${index}`),
|
|
148
|
-
),
|
|
149
|
-
);
|
|
150
|
-
},
|
|
151
|
-
);
|
|
152
|
-
|
|
153
|
-
Then(
|
|
154
|
-
"every response should contain the same ID from both plugin stages",
|
|
155
|
-
() => {
|
|
156
|
-
expect(arrivals).toBe(expectedConcurrentCount);
|
|
157
|
-
expect(concurrentResponses).toHaveLength(expectedConcurrentCount);
|
|
158
|
-
concurrentResponses.forEach((response, index) => {
|
|
159
|
-
const body = responseRecord(response);
|
|
160
|
-
expect(body.routeId).toBe(String(index));
|
|
161
|
-
expect(body.firstStageId).toBe(String(index));
|
|
162
|
-
});
|
|
163
|
-
},
|
|
164
|
-
);
|
|
165
|
-
},
|
|
166
|
-
);
|
|
167
|
-
});
|
package/src/types.ts
DELETED
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
/// <reference path="../schmock.d.ts" />
|
|
2
|
-
|
|
3
|
-
// Re-export ambient types for consumers
|
|
4
|
-
export type HttpMethod = Schmock.HttpMethod;
|
|
5
|
-
export type RouteKey = Schmock.RouteKey;
|
|
6
|
-
export type ResponseBody = Schmock.ResponseBody;
|
|
7
|
-
export type ResponseResult = Schmock.ResponseResult;
|
|
8
|
-
export type RequestContext = Schmock.RequestContext;
|
|
9
|
-
export type Response = Schmock.Response;
|
|
10
|
-
export type RequestOptions = Schmock.RequestOptions;
|
|
11
|
-
export type GlobalConfig = Schmock.GlobalConfig;
|
|
12
|
-
export type RouteConfig = Schmock.RouteConfig;
|
|
13
|
-
export type Generator = Schmock.Generator;
|
|
14
|
-
export type GeneratorFunction = Schmock.GeneratorFunction;
|
|
15
|
-
export type CallableMockInstance = Schmock.CallableMockInstance;
|
|
16
|
-
export type Plugin = Schmock.Plugin;
|
|
17
|
-
export type PluginContext = Schmock.PluginContext;
|
|
18
|
-
export type PluginResult = Schmock.PluginResult;
|
|
19
|
-
export type StaticData = Schmock.StaticData;
|
|
20
|
-
export type RequestRecord = Schmock.RequestRecord;
|
|
21
|
-
export type ServerInfo = Schmock.ServerInfo;
|
|
22
|
-
export type RouteInfo = Schmock.RouteInfo;
|
|
23
|
-
export type SchemaGenerationContext = Schmock.SchemaGenerationContext;
|
|
24
|
-
export type FakerPluginOptions = Schmock.FakerPluginOptions;
|
|
25
|
-
export type ExpressAdapterOptions = Schmock.ExpressAdapterOptions;
|
|
26
|
-
export type AngularAdapterOptions = Schmock.AngularAdapterOptions;
|
|
27
|
-
export type OpenApiOptions = Schmock.OpenApiOptions;
|
|
28
|
-
export type SeedSource = Schmock.SeedSource;
|
|
29
|
-
export type SeedConfig = Schmock.SeedConfig;
|
|
30
|
-
export type CliOptions = Schmock.CliOptions;
|
|
31
|
-
export type CliServer = Schmock.CliServer;
|
|
32
|
-
export type AdapterRequest = Schmock.AdapterRequest;
|
|
33
|
-
export type AdapterResponse = Schmock.AdapterResponse;
|
|
34
|
-
export type InterceptOptions = Schmock.InterceptOptions;
|
|
35
|
-
export type InterceptHandle = Schmock.InterceptHandle;
|
|
36
|
-
export type AdapterRequestOverride = Schmock.AdapterRequestOverride;
|