summaryrefslogtreecommitdiff
path: root/test/timers/test-timers-reliability.js
diff options
context:
space:
mode:
authorGibson Fahnestock <gibfahn@gmail.com>2017-03-09 18:11:21 +0000
committerMyles Borins <mylesborins@google.com>2017-04-18 20:01:49 -0400
commitdb61c952de2aa4591c60f4772fa62f0bc3474577 (patch)
tree9e585bb427b689eeb8ec431f6e8515595c7e6e5d /test/timers/test-timers-reliability.js
parentde636980668017c2ed155ba6f75ac5e6a2af647b (diff)
downloadnode-new-db61c952de2aa4591c60f4772fa62f0bc3474577.tar.gz
test: use eslint to fix var->const/let
Manually fix issues that eslint --fix couldn't do automatically. Backport-PR-URL: https://github.com/nodejs/node/pull/11775 PR-URL: https://github.com/nodejs/node/pull/10685 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Roman Reiss <me@silverwind.io>
Diffstat (limited to 'test/timers/test-timers-reliability.js')
-rw-r--r--test/timers/test-timers-reliability.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/timers/test-timers-reliability.js b/test/timers/test-timers-reliability.js
index 0626c45826..9a9834aefe 100644
--- a/test/timers/test-timers-reliability.js
+++ b/test/timers/test-timers-reliability.js
@@ -3,11 +3,11 @@
require('../common');
-var Timer = process.binding('timer_wrap').Timer;
-var assert = require('assert');
+const Timer = process.binding('timer_wrap').Timer;
+const assert = require('assert');
-var timerFired = false;
-var intervalFired = false;
+let timerFired = false;
+let intervalFired = false;
/*
* This test case aims at making sure that timing utilities such
@@ -31,7 +31,7 @@ var intervalFired = false;
* is vulnerable to time drift or inconsistent time changes.
*/
-var monoTimer = new Timer();
+const monoTimer = new Timer();
monoTimer[Timer.kOnTimeout] = function() {
/*
* Make sure that setTimeout's and setInterval's callbacks have
@@ -48,7 +48,7 @@ setTimeout(function() {
timerFired = true;
}, 200);
-var interval = setInterval(function() {
+const interval = setInterval(function() {
intervalFired = true;
clearInterval(interval);
}, 200);