From c7192be2b86638b6000fc5d22cc8429f6221f25e Mon Sep 17 00:00:00 2001 From: r1cebank Date: Fri, 6 Oct 2017 09:46:54 -0700 Subject: [PATCH] test: switch to use common.fixtures module for fixturesDir PR-URL: https://github.com/nodejs/node/pull/15821 Reviewed-By: Ryan Graham Reviewed-By: Colin Ihrig Reviewed-By: Benjamin Gruenbaum Reviewed-By: Luigi Pinca Reviewed-By: Gibson Fahnestock Reviewed-By: Gireesh Punathil --- test/parallel/test-tls-connect-given-socket.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/test/parallel/test-tls-connect-given-socket.js b/test/parallel/test-tls-connect-given-socket.js index b69e0b94a3c598..228f7fadad82be 100644 --- a/test/parallel/test-tls-connect-given-socket.js +++ b/test/parallel/test-tls-connect-given-socket.js @@ -2,16 +2,15 @@ const common = require('../common'); if (!common.hasCrypto) common.skip('missing crypto'); +const fixtures = require('../common/fixtures'); const assert = require('assert'); const tls = require('tls'); const net = require('net'); -const fs = require('fs'); -const path = require('path'); const options = { - key: fs.readFileSync(path.join(common.fixturesDir, 'test_key.pem')), - cert: fs.readFileSync(path.join(common.fixturesDir, 'test_cert.pem')) + key: fixtures.readSync('test_key.pem'), + cert: fixtures.readSync('test_cert.pem') }; const server = tls.createServer(options, common.mustCall((socket) => {