mirror of
https://github.com/nodejs/node.git
synced 2026-11-27 17:52:27 -05:00
test: add common.mustCall in test-http-abort-client.js
PR-URL: https://github.com/nodejs/node/pull/27449 Reviewed-By: Weijia Wang <starkwang@126.com> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com> Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
This commit is contained in:
1 parent
f4124d5ba5
commit
457549b67d
1 file changed
+2
-2
@@ -24,11 +24,11 @@ const common = require('../common');
|
||||
const http = require('http');
|
||||
|
||||
let serverRes;
|
||||
const server = http.Server((req, res) => {
|
||||
const server = http.Server(common.mustCall((req, res) => {
|
||||
serverRes = res;
|
||||
res.writeHead(200);
|
||||
res.write('Part of my res.');
|
||||
});
|
||||
}));
|
||||
|
||||
server.listen(0, common.mustCall(() => {
|
||||
http.get({
|
||||
|
||||
Reference in new issue
Block a user