mirror of
https://github.com/nodejs/node.git
synced 2025-08-15 21:58:48 +02:00
http2: adjust error emit in core, add tests
Use the ability of nextTick and setImmediate to pass arguments instead of creating closures or binding. Add tests that cover the vast majority of error emits. PR-URL: https://github.com/nodejs/node/pull/15586 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
This commit is contained in:
parent
dcd890a135
commit
ccd3afc843
11 changed files with 793 additions and 115 deletions
|
@ -81,7 +81,6 @@ server.on('stream', common.mustCall((stream, headers) => {
|
|||
const errorMustNotCall = common.mustNotCall(
|
||||
`${currentError.error.code} should emit on ${currentError.type}`
|
||||
);
|
||||
console.log(currentError);
|
||||
|
||||
if (currentError.type === 'stream') {
|
||||
stream.session.on('error', errorMustNotCall);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue