diff options
Diffstat (limited to 'test/unit/app/nodeify-test.js')
-rw-r--r-- | test/unit/app/nodeify-test.js | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/test/unit/app/nodeify-test.js b/test/unit/app/nodeify-test.js index 901603c8b..938b76c68 100644 --- a/test/unit/app/nodeify-test.js +++ b/test/unit/app/nodeify-test.js @@ -13,8 +13,12 @@ describe('nodeify', function () { it('should retain original context', function (done) { var nodified = nodeify(obj.promiseFunc, obj) nodified('baz', function (err, res) { - assert.equal(res, 'barbaz') - done() + if (!err) { + assert.equal(res, 'barbaz') + done() + } else { + done(new Error(err.toString())) + } }) }) |