Skip to content

Commit

Permalink
test: use assert.strictEqual()
Browse files Browse the repository at this point in the history
Fixes: nodejs/node-addon-api#775
PR-URL: nodejs/node-addon-api#777
Reviewed-By: Nicola Del Gobbo <[email protected]>
Reviewed-By: Gabriel Schulhof <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
  • Loading branch information
John French committed Jul 30, 2020
1 parent d1a9866 commit 323f97e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/threadsafe_function/threadsafe_function_existing_tsfn.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ module.exports = test(require(`../build/${buildType}/binding.node`))
async function test(binding) {
const testCall = binding.threadsafe_function_existing_tsfn.testCall;

assert(typeof await testCall({ blocking: true, data: true }) === "number");
assert(typeof await testCall({ blocking: true, data: false }) === "undefined");
assert(typeof await testCall({ blocking: false, data: true }) === "number");
assert(typeof await testCall({ blocking: false, data: false }) === "undefined");
assert.strictEqual(typeof await testCall({ blocking: true, data: true }), "number");
assert.strictEqual(typeof await testCall({ blocking: true, data: false }), "undefined");
assert.strictEqual(typeof await testCall({ blocking: false, data: true }), "number");
assert.strictEqual(typeof await testCall({ blocking: false, data: false }), "undefined");
}

0 comments on commit 323f97e

Please sign in to comment.