mirror of
https://github.com/nodejs/node.git
synced 2026-11-27 17:52:27 -05:00
test: use fixtures.readKey
Replace the common.fixturesDir by fixtures.readKey in http2 subsystem test 'server startup'. PR-URL: https://github.com/nodejs/node/pull/15892 Reviewed-By: Sam Roberts <vieuxtech@gmail.com> Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
This commit is contained in:
1 parent
f7ab12685e
commit
6a44442b5f
1 file changed
+3
-6
@@ -6,22 +6,19 @@
|
||||
// other than start listening.
|
||||
|
||||
const common = require('../common');
|
||||
const commonFixtures = require('../common/fixtures');
|
||||
|
||||
if (!common.hasCrypto)
|
||||
common.skip('missing crypto');
|
||||
|
||||
const assert = require('assert');
|
||||
const http2 = require('http2');
|
||||
const path = require('path');
|
||||
const tls = require('tls');
|
||||
const net = require('net');
|
||||
const fs = require('fs');
|
||||
|
||||
const options = {
|
||||
key: fs.readFileSync(
|
||||
path.resolve(common.fixturesDir, 'keys/agent2-key.pem')),
|
||||
cert: fs.readFileSync(
|
||||
path.resolve(common.fixturesDir, 'keys/agent2-cert.pem'))
|
||||
key: commonFixtures.readKey('agent2-key.pem'),
|
||||
cert: commonFixtures.readKey('agent2-cert.pem')
|
||||
};
|
||||
|
||||
// There should not be any throws
|
||||
|
||||
Reference in new issue
Block a user