MCPcopy Index your code
hub / github.com/github-tools/github / assertFailure

Function assertFailure

test/helpers/callbacks.js:24–42  ·  view source on GitHub ↗
(done, cb)

Source from the content-addressed store, hash-verified

22}
23
24export function assertFailure(done, cb) {
25 return function failureCallback(err) {
26 try {
27 expect(err).to.exist();
28 expect(err).to.have.ownProperty('path');
29 expect(err.request).to.exist();
30
31 if (cb) {
32 setTimeout(function delay() {
33 cb(err);
34 }, STANDARD_DELAY);
35 } else {
36 done();
37 }
38 } catch (e) {
39 done(e);
40 }
41 };
42}
43
44export function assertArray(done) {
45 return assertSuccessful(done, function isArray(err, result) {

Callers 4

auth.spec.jsFile · 0.90
team.spec.jsFile · 0.90
error.spec.jsFile · 0.90
repository.spec.jsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…