MCPcopy
hub / github.com/forwardemail/supertest / error

Function error

lib/test.js:391–397  ·  view source on GitHub ↗

* Return an `Error` with `msg` and results properties. * * @param {String} msg * @param {Mixed} expected * @param {Mixed} actual * @return {Error} * @api private

(msg, expected, actual)

Source from the content-addressed store, hash-verified

389 */
390
391function error(msg, expected, actual) {
392 const err = new Error(msg);
393 err.expected = expected;
394 err.actual = actual;
395 err.showDiff = true;
396 return err;
397}
398
399/**
400 * Expose `Test`.

Callers 1

_assertBodyMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…