Skip to content

Commit

Permalink
test: replace common.fixtiresDir with readFixtureKey
Browse files Browse the repository at this point in the history
  • Loading branch information
wsierakowski authored and Trott committed Nov 8, 2017
1 parent eebcb48 commit 2e90766
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions test/parallel/test-tls-js-stream.js
Original file line number Diff line number Diff line change
@@ -1,22 +1,24 @@
'use strict';
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 stream = require('stream');
const fs = require('fs');
const net = require('net');
const stream = require('stream');
const tls = require('tls');

const connected = {
client: 0,
server: 0
};

const server = tls.createServer({
key: fs.readFileSync(`${common.fixturesDir}/keys/agent1-key.pem`),
cert: fs.readFileSync(`${common.fixturesDir}/keys/agent1-cert.pem`)
key: fixtures.readKey('agent1-key.pem'),
cert: fixtures.readKey('agent1-cert.pem')
}, function(c) {
console.log('new client');
connected.server++;
Expand Down

0 comments on commit 2e90766

Please sign in to comment.