Skip to content
On this page

inspect

Prints request & response details to the console.

TIP

  • Use it for debugging purpose.
  • By default, request and response are printed to the terminal when a test case fails.

Syntax

js
inspect()
inspect('path')
  • path (string) - json path. Visit json-query for more usage details.

Usage

โœ… Correct Usage

js
await spec()
  .get('/api/users/1')
  .inspect();
js
await spec()
  .get('/api/users/1')
  .inspect('name')
  .inspect('age');

Released under the MIT License.