Skip to content

Commit 47b7f2a

Browse files
Oktavianus Ludirojasnell
Oktavianus Ludiro
authored andcommitted
test: use correct argument order for assert.strictEqual()
The previous code did not pass correct argument order to assert.strictEqual(). Before: First argument provided is expected value Second argument provided is actual value After: First argument provided is actual value Second argument provided is expected value PR-URL: #23527 Reviewed-By: Hitesh Kanwathirtha <digitalinfinity@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
1 parent 1fd1e60 commit 47b7f2a

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

test/pummel/test-fs-watch-file.js

+5-5
Original file line numberDiff line numberDiff line change
@@ -50,10 +50,10 @@ process.on('exit', function() {
5050
fs.unlinkSync(filepathTwoAbs);
5151
fs.unlinkSync(filenameThree);
5252
fs.unlinkSync(filenameFour);
53-
assert.strictEqual(1, watchSeenOne);
54-
assert.strictEqual(2, watchSeenTwo);
55-
assert.strictEqual(1, watchSeenThree);
56-
assert.strictEqual(1, watchSeenFour);
53+
assert.strictEqual(watchSeenOne, 1);
54+
assert.strictEqual(watchSeenTwo, 2);
55+
assert.strictEqual(watchSeenThree, 1);
56+
assert.strictEqual(watchSeenFour, 1);
5757
});
5858

5959

@@ -134,7 +134,7 @@ setTimeout(function() {
134134
{ // Does not throw.
135135
function a() {
136136
++watchSeenFour;
137-
assert.strictEqual(1, watchSeenFour);
137+
assert.strictEqual(watchSeenFour, 1);
138138
fs.unwatchFile(`.${path.sep}${filenameFour}`, a);
139139
}
140140
fs.watchFile(filenameFour, a);

0 commit comments

Comments
 (0)