-
Notifications
You must be signed in to change notification settings - Fork 30.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test: replace common.fixturesDir with common.fixtures #15862
test: replace common.fixturesDir with common.fixtures #15862
Conversation
Hi, @kasimdoctor! Welcome and thanks for this! Can you update it to use |
@@ -13,7 +14,7 @@ const h2 = require('http2'); | |||
|
|||
function loadKey(keyname) { | |||
return fs.readFileSync( | |||
path.join(common.fixturesDir, 'keys', keyname), 'binary'); | |||
path.join(fixtures.fixturesDir, 'keys', keyname), 'binary'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can be:
return fixtures.readKey(keyname, 'binary');
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point.
@@ -1,6 +1,7 @@ | |||
'use strict'; | |||
|
|||
const common = require('../common'); | |||
const fixtures = require('../common/fixtures'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: would you mind moving this after the common.hasCrypto
check?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure.
676866d
to
cec9148
Compare
@@ -5,15 +5,16 @@ const common = require('../common'); | |||
if (!common.hasCrypto) | |||
common.skip('missing crypto'); | |||
|
|||
const fixtures = require('../common/fixtures'); | |||
|
|||
const assert = require('assert'); | |||
const path = require('path'); | |||
const fs = require('fs'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We no longer need fs
as it is no longer used, can you please remove it? The linter is not happy if we keep it :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh yea, missed that. Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with the last nit fixed.
cec9148
to
b724b96
Compare
@lpinca Done. |
Looking at the linter output, I realized that |
@kasimdoctor correct, if you can please do it :) |
…2-create-client-secure-session.js
b724b96
to
6c5db36
Compare
@lpinca Done, please trigger CI again. Thanks! |
@lpinca Strange, but I no longer can check the status of the CI builds. I get the Read permission denied. Is this intentional? |
No it isn't intentional afaik. Anyway there is only a failure which is unrelated to this change. |
Landed in d828c01. Thank you! |
Use `fixtures.readKey()` in test-http2-create-client-secure-session.js. PR-URL: #15862 Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Thanks @lpinca! Safe to delete the branch I guess? |
@kasimdoctor Yes. |
Use `fixtures.readKey()` in test-http2-create-client-secure-session.js. PR-URL: nodejs/node#15862 Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Use `fixtures.readKey()` in test-http2-create-client-secure-session.js. PR-URL: #15862 Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Use `fixtures.readKey()` in test-http2-create-client-secure-session.js. PR-URL: #15862 Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Action-> Replaced
common.fixturesDir
intest-http2-create-client-secure-session.js
withcommon.fixtures
moduleChecklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passesAffected core subsystem(s)
test