Browse Source

test: update test to use fixtures module

Updated the test-http2-create-client-connect tests to
use the test fixures module instead of the common
module.

PR-URL: https://github.com/nodejs/node/pull/15955
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
v9.x-staging
gbugaisky 7 years ago
committed by Joyee Cheung
parent
commit
5ca1c7a9c5
  1. 7
      test/parallel/test-http2-create-client-connect.js

7
test/parallel/test-http2-create-client-connect.js

@ -5,9 +5,8 @@
const common = require('../common'); const common = require('../common');
if (!common.hasCrypto) if (!common.hasCrypto)
common.skip('missing crypto'); common.skip('missing crypto');
const fs = require('fs'); const fixtures = require('../common/fixtures');
const h2 = require('http2'); const h2 = require('http2');
const path = require('path');
const url = require('url'); const url = require('url');
const URL = url.URL; const URL = url.URL;
@ -51,8 +50,8 @@ const URL = url.URL;
{ {
const options = { const options = {
key: fs.readFileSync(path.join(common.fixturesDir, 'keys/agent3-key.pem')), key: fixtures.readKey('agent3-key.pem'),
cert: fs.readFileSync(path.join(common.fixturesDir, 'keys/agent3-cert.pem')) cert: fixtures.readKey('agent3-cert.pem')
}; };
const server = h2.createSecureServer(options); const server = h2.createSecureServer(options);

Loading…
Cancel
Save