Skip to content

Commit

Permalink
test: switch to use common.fixtures module for fixturesDir
Browse files Browse the repository at this point in the history
PR-URL: #15821
Reviewed-By: Ryan Graham <r.m.graham@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
  • Loading branch information
r1cebank authored and MylesBorins committed Nov 28, 2017
1 parent 71e6879 commit 77f9ef3
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions test/parallel/test-tls-connect-given-socket.js
Original file line number Diff line number Diff line change
Expand Up @@ -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) => {
Expand Down

0 comments on commit 77f9ef3

Please sign in to comment.