Skip to content

Commit

Permalink
test: use common.fixtures in tls test
Browse files Browse the repository at this point in the history
PR-URL: #15965
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: Tobias Nießen <[email protected]>
  • Loading branch information
Ben Michel authored and MylesBorins committed Oct 11, 2017
1 parent 9f9bd38 commit 329d22f
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions test/parallel/test-tls-max-send-fragment.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,20 +21,21 @@

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

if (!common.hasCrypto)
common.skip('missing crypto');

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

const buf = Buffer.allocUnsafe(10000);
let received = 0;
const maxChunk = 768;

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) {
// Lower and upper limits
assert(!c.setMaxSendFragment(511));
Expand Down

0 comments on commit 329d22f

Please sign in to comment.