Debugging
You can enable debugging in two ways:
- set
REQUEST_MOCKING_DEBUG=1env variable to debug all mocks - set
debug: trueon any request/response schema to debug the specific mock
await mockClient.GET(
{
url: 'https://example.com/*',
query: { foo: 'bar' },
debug: true, // <-- enable debugging via request schema
},
{
body: { id: 1, name: 'John Smith' },
debug: true, // <-- or enable debugging via response schema
},
);
When debug enabled, the server will output mocking logs to console:
