mirror of
https://github.com/zebrajr/node.git
synced 2026-01-15 12:15:26 +00:00
test: favor === over == in test-timers.js
Use `===` instead of `==` in pummel/test-timers.js PR-URL: https://github.com/nodejs/node/pull/8131 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
@@ -39,7 +39,7 @@ setInterval(function() {
|
||||
assert.equal(true, t - WINDOW < diff && diff < t + WINDOW);
|
||||
|
||||
assert.equal(true, interval_count <= 3);
|
||||
if (interval_count == 3)
|
||||
if (interval_count === 3)
|
||||
clearInterval(this);
|
||||
}, 1000);
|
||||
|
||||
@@ -54,7 +54,7 @@ setInterval(function(param) {
|
||||
++interval_count2;
|
||||
assert.equal('test param', param);
|
||||
|
||||
if (interval_count2 == 3)
|
||||
if (interval_count2 === 3)
|
||||
clearInterval(this);
|
||||
}, 1000, 'test param');
|
||||
|
||||
@@ -71,7 +71,7 @@ setInterval(function(param1, param2) {
|
||||
assert.equal('param1', param1);
|
||||
assert.equal('param2', param2);
|
||||
|
||||
if (interval_count3 == 3)
|
||||
if (interval_count3 === 3)
|
||||
clearInterval(this);
|
||||
}, 1000, 'param1', 'param2');
|
||||
|
||||
|
||||
Reference in New Issue
Block a user