Skip to content

Commit b49df0b

Browse files
Lam Chantargos
Lam Chan
authored andcommitted
test: replaced fs.readSync with fixtures.readSync
NINA 2017 Code and Learn session for first time contributors. This touched test/parallel/test-https-socket-options.js to replace common.fixturesDir PR-URL: #15882 Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Gireesh Punathil <[email protected]>
1 parent ae3836a commit b49df0b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

test/parallel/test-https-socket-options.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,13 @@ const common = require('../common');
2525
if (!common.hasCrypto)
2626
common.skip('missing crypto');
2727

28+
const fixtures = require('../common/fixtures');
2829
const https = require('https');
29-
const fs = require('fs');
3030
const http = require('http');
3131

3232
const options = {
33-
key: fs.readFileSync(`${common.fixturesDir}/keys/agent1-key.pem`),
34-
cert: fs.readFileSync(`${common.fixturesDir}/keys/agent1-cert.pem`)
33+
key: fixtures.readKey('agent1-key.pem'),
34+
cert: fixtures.readKey('agent1-cert.pem')
3535
};
3636

3737
const body = 'hello world\n';

0 commit comments

Comments
 (0)