From 861e584d466035462f3c7693b8381101f1f4cb6f Mon Sep 17 00:00:00 2001 From: yorkie Date: Sat, 20 Aug 2016 21:37:59 +0800 Subject: [PATCH] async_wrap: add a missing case to test-async-wrap-throw-no-init PR-URL: https://github.com/nodejs/node/pull/8198 Reviewed-By: James M Snell Reviewed-By: Trevor Norris --- test/parallel/test-async-wrap-throw-no-init.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/test/parallel/test-async-wrap-throw-no-init.js b/test/parallel/test-async-wrap-throw-no-init.js index ccf77f66dc7232..1f8cc70b36c6e7 100644 --- a/test/parallel/test-async-wrap-throw-no-init.js +++ b/test/parallel/test-async-wrap-throw-no-init.js @@ -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/);