test: change var to let

PR-URL: https://github.com/nodejs/node/pull/34902
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Harshitha K P <harshitha014@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
This commit is contained in:
Pooja D.P authored and Tobias Nießen committed 2020-09-05 12:53:45 +02:00
1 parent 186230527b
commit 00000000fb
1 file changed
+2 -2
+2 -2
View File
@@ -25,7 +25,7 @@ child.stdin.write = function(original) {
}(child.stdin.write);
child.stdout.once('data', function() {
child.stdin.write('var throws = 0;');
child.stdin.write('let throws = 0;');
child.stdin.write('process.on("exit",function(){console.log(throws)});');
child.stdin.write('function thrower(){console.log("THROW",throws++);XXX};');
child.stdin.write('setTimeout(thrower);""\n');
@@ -40,7 +40,7 @@ child.stdout.once('data', function() {
function eeTest() {
child.stdin.write('setTimeout(function() {\n' +
' const events = require("events");\n' +
' var e = new events.EventEmitter;\n' +
' let e = new events.EventEmitter;\n' +
' process.nextTick(function() {\n' +
' e.on("x", thrower);\n' +
' setTimeout(function() {\n' +