From fa4f1587d34c8d18ab93b7c3e9fc37d7e05697a9 Mon Sep 17 00:00:00 2001 From: Amar Zavery Date: Thu, 1 Dec 2016 10:27:02 -0600 Subject: [PATCH] test: replace var with const in test-require-dot PR-URL: https://github.com/nodejs/node/pull/9916 Reviewed-By: Colin Ihrig Reviewed-By: Teddy Katz Reviewed-By: Gibson Fahnestock Reviewed-By: James M Snell Reviewed-By: Italo A. Casas --- test/parallel/test-require-dot.js | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/test/parallel/test-require-dot.js b/test/parallel/test-require-dot.js index 2fb161486a9241..26733c7fc438a1 100644 --- a/test/parallel/test-require-dot.js +++ b/test/parallel/test-require-dot.js @@ -1,17 +1,17 @@ 'use strict'; -var common = require('../common'); -var assert = require('assert'); -var module = require('module'); +const common = require('../common'); +const assert = require('assert'); +const m = require('module'); -var a = require(common.fixturesDir + '/module-require/relative/dot.js'); -var b = require(common.fixturesDir + '/module-require/relative/dot-slash.js'); +const a = require(common.fixturesDir + '/module-require/relative/dot.js'); +const b = require(common.fixturesDir + '/module-require/relative/dot-slash.js'); -assert.equal(a.value, 42); -assert.equal(a, b, 'require(".") should resolve like require("./")'); +assert.strictEqual(a.value, 42); +assert.strictEqual(a, b, 'require(".") should resolve like require("./")'); process.env.NODE_PATH = common.fixturesDir + '/module-require/relative'; -module._initPaths(); +m._initPaths(); -var c = require('.'); +const c = require('.'); -assert.equal(c.value, 42, 'require(".") should honor NODE_PATH'); +assert.strictEqual(c.value, 42, 'require(".") should honor NODE_PATH');