Skip to content

Commit

Permalink
test: replace fixturesDir in test-tls-connect
Browse files Browse the repository at this point in the history
Replace common.fixturesDir with fixtures module in test-tls-connect.

PR-URL: #15849
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: Joyee Cheung <[email protected]>
  • Loading branch information
Casie Lynch authored and gibfahn committed Oct 31, 2017
1 parent ce07cbe commit d185bfd
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions test/parallel/test-tls-connect.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,16 @@ const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');

const fixtures = require('../common/fixtures');

const assert = require('assert');
const fs = require('fs');
const path = require('path');
const tls = require('tls');

// https://github.com/joyent/node/issues/1218
// uncatchable exception on TLS connection error
{
const cert = fs.readFileSync(path.join(common.fixturesDir, 'test_cert.pem'));
const key = fs.readFileSync(path.join(common.fixturesDir, 'test_key.pem'));
const cert = fixtures.readSync('test_cert.pem');
const key = fixtures.readSync('test_key.pem');

const options = { cert: cert, key: key, port: common.PORT };
const conn = tls.connect(options, common.mustNotCall());
Expand All @@ -47,8 +47,8 @@ const tls = require('tls');

// SSL_accept/SSL_connect error handling
{
const cert = fs.readFileSync(path.join(common.fixturesDir, 'test_cert.pem'));
const key = fs.readFileSync(path.join(common.fixturesDir, 'test_key.pem'));
const cert = fixtures.readSync('test_cert.pem');
const key = fixtures.readSync('test_key.pem');

const conn = tls.connect({
cert: cert,
Expand Down

0 comments on commit d185bfd

Please sign in to comment.