summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpotham <pothamk@gmail.com>2018-11-17 17:41:00 +0530
committerRich Trott <rtrott@gmail.com>2018-11-17 21:07:52 -0800
commitf25123822e6f1a64ebd7ebb5f046780d56b9e6af (patch)
tree6746ec3661a97b342393500bd1c896ac5bf69fdf
parentb3b5fc7c065c6aba1eca34a61dd085c2987a55f5 (diff)
downloadnode-new-f25123822e6f1a64ebd7ebb5f046780d56b9e6af.tar.gz
test: replace callback functions with arrow functions
PR-URL: https://github.com/nodejs/node/pull/24432 Reviewed-By: Michaƫl Zasso <targos@protonmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
-rw-r--r--test/parallel/test-http-client-timeout-option-with-agent.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/parallel/test-http-client-timeout-option-with-agent.js b/test/parallel/test-http-client-timeout-option-with-agent.js
index 26c93ec55b..7f20eb4e13 100644
--- a/test/parallel/test-http-client-timeout-option-with-agent.js
+++ b/test/parallel/test-http-client-timeout-option-with-agent.js
@@ -24,7 +24,7 @@ const server = http.createServer(() => {
// Never respond.
});
-server.listen(0, options.host, function() {
+server.listen(0, options.host, () => {
doRequest();
});
@@ -50,7 +50,7 @@ function doRequest() {
}));
req.end();
- setTimeout(function() {
+ setTimeout(() => {
req.destroy();
assert.strictEqual(timeout_events, 1);
// Ensure the `timeout` event fired only once.