-
Notifications
You must be signed in to change notification settings - Fork 30k
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: add test for http outgoing internal headers #13980
Conversation
|
||
const outHeadersKey = require('internal/http').outHeadersKey; | ||
const http = require('http'); | ||
const OutgoingMessage = http.OutgoingMessage; |
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.
Perhaps just:
const { OutgoingMessage } = require('http');
The first word after the This can be fixed by whoever lands the pull request, but if you do it for them, it will save them a few keystrokes. See commit message guidelines at https://github.com/nodejs/node/blob/master/CONTRIBUTING.md#commit-message-guidelines. (You probably saw them and were trying to follow them but there's a lot of stuff there so it's easy to miss a small thing here or there.) |
is there anything else I should fix? |
@nodejs/testing @nodejs/http |
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.
My only comment would be to separate the tests using block scopes. It prevents the tests from interacting with each other and eliminates numbers on the end of the variable names (outgoingMessage2
).
should be fixed @cjihrig |
const common = require('../common'); | ||
const assert = require('assert'); | ||
|
||
const outHeadersKey = require('internal/http').outHeadersKey; |
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.
For consistency...
const { outHeadersKey } = require('internal/http');
host: ['host', 'risingstack.com'], | ||
origin: ['Origin', 'localhost'] | ||
}); | ||
} |
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.
lint: file needs to end with \n
Looks like this needs a |
should be all fixed :) |
@refack is it me who should fi things, or the CI has some issues? |
@gergelyke CI had issues. AFAICT the jobs that did finish were green. |
PR-URL: nodejs#13980 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com>
Landed in f406a7e |
Extra sanity test on |
PR-URL: #13980 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com>
PR-URL: #13980 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com>
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passesAffected core subsystem(s)
http