Skip to content

Commit

Permalink
test: remove message argument from strictEqual()
Browse files Browse the repository at this point in the history
In test/parallel/test-require-process.js, the last thing in the test is
a call to assert.strictEqual(). It has a string literal as its third
argument. Unfortunately, that means that the diff between the two values
being compared will be suppressed if there is an AssertionError. That's
not helpful for debugging.

This is fixed by removing the third argument from the call. It is,
however, preserved in a comment above the call to assert.strictEqual().

PR-URL: #20912
Fixes: #20911
Refs: https://www.nodetodo.org/getting-started
Reviewed-By: Benjamin Gruenbaum <[email protected]>
Reviewed-By: Rich Trott <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Trivikram Kamat <[email protected]>
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: Ujjwal Sharma <[email protected]>
Reviewed-By: Ruben Bridgewater <[email protected]>
  • Loading branch information
sagirk authored and targos committed May 25, 2018
1 parent 40e5788 commit 82afb4c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/parallel/test-require-process.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ require('../common');
const assert = require('assert');

const nativeProcess = require('process');
assert.strictEqual(nativeProcess, process,
'require("process") should return global process reference');
// require('process') should return global process reference
assert.strictEqual(nativeProcess, process);

0 comments on commit 82afb4c

Please sign in to comment.