Skip to content

Commit

Permalink
test: cleanup test-fs-watch.js
Browse files Browse the repository at this point in the history
Reversed "actual" and "expected" arguments for assert.strictEqual().

Replaced constructor with regular expression for assert.throws().

PR-URL: nodejs/node#12595
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Bryan English <bryan@bryanenglish.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
  • Loading branch information
RobotMermaid authored and andrew749 committed Jul 19, 2017
1 parent 9171b6f commit 03441f8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/sequential/test-fs-watch.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ assert.doesNotThrow(
function() {
const watcher = fs.watch(testsubdir, function(event, filename) {
const renameEv = common.isSunOS || common.isAix ? 'change' : 'rename';
assert.strictEqual(renameEv, event);
assert.strictEqual(event, renameEv);
if (expectFilePath) {
assert.strictEqual(filename, 'newfile.txt');
} else {
Expand Down

0 comments on commit 03441f8

Please sign in to comment.