From 1de9402897a0d5589ddd710d6a6d2b65b469cc84 Mon Sep 17 00:00:00 2001 From: Narcisa C <10314636+narcisacodreanu@users.noreply.github.com> Date: Sat, 23 Sep 2023 14:37:17 -0400 Subject: [PATCH] test: replace forEach() in test-net-perf_hooks with for of --- test/parallel/test-net-perf_hooks.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/parallel/test-net-perf_hooks.js b/test/parallel/test-net-perf_hooks.js index 6b0d13aab27019..06b88ed7e7e7b9 100644 --- a/test/parallel/test-net-perf_hooks.js +++ b/test/parallel/test-net-perf_hooks.js @@ -49,12 +49,12 @@ obs.observe({ type: 'net' }); process.on('exit', () => { assert.strictEqual(entries.length, 1); - entries.forEach((entry) => { + for (const entry of entries) { assert.strictEqual(entry.name, 'connect'); assert.strictEqual(entry.entryType, 'net'); assert.strictEqual(typeof entry.startTime, 'number'); assert.strictEqual(typeof entry.duration, 'number'); assert.strictEqual(!!entry.detail.host, true); assert.strictEqual(!!entry.detail.port, true); - }); + } });