hyperactive
Advanced tools
Comparing version
{ | ||
"name": "hyperactive", | ||
"version": "2.2.1", | ||
"version": "2.2.2", | ||
"description": "Creates mocha tests for all hypermedia of your API", | ||
@@ -5,0 +5,0 @@ "author": "Tabcorp Digital Technology Team", |
@@ -70,12 +70,14 @@ // Generated by CoffeeScript 1.7.1 | ||
if (!config.recover(res)) { | ||
return done("Bad status " + res.status + " for url " + res.url); | ||
err = "Bad status " + res.status + " for url " + res.url; | ||
} | ||
} | ||
try { | ||
if (!validate(parent, res)) { | ||
return done("Not a valid response: " + res.body); | ||
return done(err); | ||
} else { | ||
try { | ||
if (!validate(parent, res)) { | ||
return done("Not a valid response: " + res.body); | ||
} | ||
} catch (_error) { | ||
err = _error; | ||
return done(err); | ||
} | ||
} catch (_error) { | ||
err = _error; | ||
return done(err); | ||
} | ||
@@ -82,0 +84,0 @@ return describe("" + parent, function() { |
12859
0.39%201
1.01%