Browse Source

test: refactor test-require-resolve

* var => const
* assert.equal() => assert.strictEqual()

PR-URL: https://github.com/nodejs/node/pull/10120
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
v6
blugavere 8 years ago
committed by Rich Trott
parent
commit
2df3fd9856
  1. 16
      test/parallel/test-require-resolve.js

16
test/parallel/test-require-resolve.js

@ -1,18 +1,18 @@
'use strict';
var common = require('../common');
var fixturesDir = common.fixturesDir;
var assert = require('assert');
var path = require('path');
const common = require('../common');
const fixturesDir = common.fixturesDir;
const assert = require('assert');
const path = require('path');
assert.equal(
assert.strictEqual(
path.join(__dirname, '../fixtures/a.js').toLowerCase(),
require.resolve('../fixtures/a').toLowerCase());
assert.equal(
assert.strictEqual(
path.join(fixturesDir, 'a.js').toLowerCase(),
require.resolve(path.join(fixturesDir, 'a')).toLowerCase());
assert.equal(
assert.strictEqual(
path.join(fixturesDir, 'nested-index', 'one', 'index.js').toLowerCase(),
require.resolve('../fixtures/nested-index/one').toLowerCase());
assert.equal('path', require.resolve('path'));
assert.strictEqual('path', require.resolve('path'));
console.log('ok');

Loading…
Cancel
Save