MCPcopy Create free account
hub / github.com/chartbrew/chartbrew / createMockResponse

Function createMockResponse

server/tests/integration/updateRunRoute.test.js:30–47  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

28}
29
30function createMockResponse() {
31 return {
32 statusCode: 200,
33 body: undefined,
34 status(code) {
35 this.statusCode = code;
36 return this;
37 },
38 send(payload) {
39 this.body = payload;
40 return this;
41 },
42 json(payload) {
43 this.body = payload;
44 return this;
45 },
46 };
47}
48
49async function executeRouteHandlers(handlers, requestOverrides = {}) {
50 const req = {

Callers 1

executeRouteHandlersFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected