From fdc55ef02cf4c70b5104fae24d78580c067e6bcb Mon Sep 17 00:00:00 2001 From: Christopher Rokita Date: Thu, 1 Dec 2016 12:20:25 -0500 Subject: [PATCH] test: use const or let and assert.strictEqual PR-URL: https://github.com/nodejs/node/pull/10001 Reviewed-By: Michael Dawson Reviewed-By: Colin Ihrig Reviewed-By: James M Snell --- test/parallel/test-fs-read-file-sync.js | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/test/parallel/test-fs-read-file-sync.js b/test/parallel/test-fs-read-file-sync.js index d34bf7748cea89..45d08f40111f78 100644 --- a/test/parallel/test-fs-read-file-sync.js +++ b/test/parallel/test-fs-read-file-sync.js @@ -1,13 +1,13 @@ 'use strict'; -var common = require('../common'); -var assert = require('assert'); -var path = require('path'); -var fs = require('fs'); +const common = require('../common'); +const assert = require('assert'); +const path = require('path'); +const fs = require('fs'); -var fn = path.join(common.fixturesDir, 'elipses.txt'); +const fn = path.join(common.fixturesDir, 'elipses.txt'); -var s = fs.readFileSync(fn, 'utf8'); -for (var i = 0; i < s.length; i++) { - assert.equal('\u2026', s[i]); +const s = fs.readFileSync(fn, 'utf8'); +for (let i = 0; i < s.length; i++) { + assert.strictEqual('\u2026', s[i]); } -assert.equal(10000, s.length); +assert.strictEqual(10000, s.length);