refactor : test-http-request-dont-override-options to use common.mustCall#17438
refactor : test-http-request-dont-override-options to use common.mustCall#17438mithunsasidharan wants to merge 1 commit intonodejs:masterfrom mithunsasidharan:pr_8
Conversation
|
@apapirovski : Thanks for the feedback. I've updated the PR to include the recommended changes. Kindly review the PR now. |
There was a problem hiding this comment.
common.mustCall should be added to this function.
There was a problem hiding this comment.
We don't need to call on here since listen (line 13) accepts a callback.
There was a problem hiding this comment.
You could just put server.close() after res.resume() and then validate the assert conditions there (lines 37-42). That way we don't need the process.on('exit').
There was a problem hiding this comment.
This can be removed if server.close() is added somewhere as per above.
|
@apapirovski : Thanks for the feedback. I've updated the PR addressing the review comments. Kindly review the PR. Thanks! |
There was a problem hiding this comment.
Can this be just inlined above? The name isn't very descriptive (and could confuse someone in the future) since there's only 1 test, not many.
server.listen(0, () => {...});
There was a problem hiding this comment.
@apapirovski : Thanks for the feedback. I've updated the PR as per the comment and also shortened the commit message. Kindly review the PR now. Thanks !
|
Landing... |
|
Landed in 00c5b06 |
…stCall PR-URL: #17438 Reviewed-By: Anatoli Papirovski <[email protected]> Reviewed-By: Jon Moss <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
…stCall PR-URL: #17438 Reviewed-By: Anatoli Papirovski <[email protected]> Reviewed-By: Jon Moss <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
…stCall PR-URL: #17438 Reviewed-By: Anatoli Papirovski <[email protected]> Reviewed-By: Jon Moss <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
…stCall PR-URL: #17438 Reviewed-By: Anatoli Papirovski <[email protected]> Reviewed-By: Jon Moss <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
…stCall PR-URL: #17438 Reviewed-By: Anatoli Papirovski <[email protected]> Reviewed-By: Jon Moss <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
refactor :
test-http-request-dont-override-optionsto usecommon.mustCallas per issue #17169Checklist
make -j4 test(UNIX), orvcbuild test(Windows) passesAffected core subsystem(s)
test