test: convert anonymous function to arrow function

PR-URL: https://github.com/nodejs/node/pull/39604
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Zijian Liu <lxxyxzj@gmail.com>
This commit is contained in:
Himadri Ganguly authored and Node.js GitHub Bot committed 2021-08-02 13:22:00 +00:00
1 parent ac621ff5e7
commit fcc3910dd4
1 file changed
+2 -2
+2 -2
View File
@@ -29,7 +29,7 @@ const http = require('http');
res.end();
}));
server.listen(0, common.mustCall(function() {
server.listen(0, common.mustCall(() => {
http.get({ port: server.address().port }, common.mustCall((res) => {
assert.strictEqual(res.headers.test, '1');
assert.strictEqual(res.headers.test2, '2');
@@ -51,7 +51,7 @@ const http = require('http');
res.end();
}));
server.listen(0, common.mustCall(function() {
server.listen(0, common.mustCall(() => {
http.get({ port: server.address().port }, common.mustCall((res) => {
res.resume().on('end', common.mustCall(() => {
server.close();