From 47169216d82ab6e122f3df9d217d222b017c21ec Mon Sep 17 00:00:00 2001 From: Greg Byram Date: Fri, 6 Oct 2017 12:56:47 -0400 Subject: [PATCH] test: use fixtures.readKey in https-agent test PR-URL: https://github.com/nodejs/node/pull/15913 Reviewed-By: Gibson Fahnestock Reviewed-By: Colin Ihrig --- test/parallel/test-https-agent-create-connection.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/test/parallel/test-https-agent-create-connection.js b/test/parallel/test-https-agent-create-connection.js index 267030232dcf9b..4ad3554f791524 100644 --- a/test/parallel/test-https-agent-create-connection.js +++ b/test/parallel/test-https-agent-create-connection.js @@ -1,6 +1,7 @@ 'use strict'; const common = require('../common'); +const fixtures = require('../common/fixtures'); if (!common.hasCrypto) common.skip('missing crypto'); @@ -9,11 +10,9 @@ const https = require('https'); const agent = new https.Agent(); -const fs = require('fs'); - const options = { - 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'), }; const expectedHeader = /^HTTP\/1\.1 200 OK/;