From b1506f713c8866c47d17b0d7fe76fd5c6697ef42 Mon Sep 17 00:00:00 2001 From: Matthew Meyer Date: Fri, 6 Oct 2017 11:11:04 -0700 Subject: [PATCH] test: use fixtures.path instead of fixturesDir MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Updated parallel/test-require-resolve.js to use the fixtures module. PR-URL: https://github.com/nodejs/node/pull/15984 Reviewed-By: James M Snell Reviewed-By: Luigi Pinca Reviewed-By: Ruben Bridgewater Reviewed-By: Tobias Nießen --- test/parallel/test-require-resolve.js | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/test/parallel/test-require-resolve.js b/test/parallel/test-require-resolve.js index b39b4c93a02017..27fb3f71f795ce 100644 --- a/test/parallel/test-require-resolve.js +++ b/test/parallel/test-require-resolve.js @@ -20,20 +20,19 @@ // USE OR OTHER DEALINGS IN THE SOFTWARE. 'use strict'; -const common = require('../common'); -const fixturesDir = common.fixturesDir; +require('../common'); +const fixtures = require('../common/fixtures'); const assert = require('assert'); -const path = require('path'); assert.strictEqual( - path.join(__dirname, '../fixtures/a.js').toLowerCase(), - require.resolve('../fixtures/a').toLowerCase()); + fixtures.path('a.js').toLowerCase(), + require.resolve(fixtures.path('a').toLowerCase())); assert.strictEqual( - path.join(fixturesDir, 'a.js').toLowerCase(), - require.resolve(path.join(fixturesDir, 'a')).toLowerCase()); + fixtures.path('a.js').toLowerCase(), + require.resolve(fixtures.path('a')).toLowerCase()); assert.strictEqual( - path.join(fixturesDir, 'nested-index', 'one', 'index.js').toLowerCase(), - require.resolve('../fixtures/nested-index/one').toLowerCase()); + fixtures.path('nested-index', 'one', 'index.js').toLowerCase(), + require.resolve(fixtures.path('nested-index', 'one').toLowerCase())); assert.strictEqual('path', require.resolve('path')); console.log('ok');