Skip to content

Commit

Permalink
async_wrap: add a missing case to test-async-wrap-throw-no-init
Browse files Browse the repository at this point in the history
PR-URL: #8198
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
  • Loading branch information
yorkie authored and Myles Borins committed Oct 10, 2016
1 parent ade85c6 commit 0e94765
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion test/parallel/test-async-wrap-throw-no-init.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,14 @@ require('../common');
const assert = require('assert');
const async_wrap = process.binding('async_wrap');


assert.throws(function() {
async_wrap.setupHooks(null);
}, /first argument must be an object/);

assert.throws(function() {
async_wrap.setupHooks({});
}, /init callback must be a function/);

assert.throws(function() {
async_wrap.enable();
}, /init callback is not assigned to a function/);
Expand Down

0 comments on commit 0e94765

Please sign in to comment.