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 <gpunathi@in.ibm.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
  • Loading branch information
Casie Lynch authored and MylesBorins committed Nov 28, 2017
1 parent d6dc579 commit 8e62fcb
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 @@ -4,16 +4,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.fail);
Expand All @@ -26,8 +26,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 8e62fcb

Please sign in to comment.