Skip to content
Browse files

test: verify listener leak is only emitted once

When a possible listener leak is detected, a warning is
emitted. This commit updates an existing test to verify that the
warning is only emitted once.

PR-URL: #12502
Reviewed-By: Sakthipriyan Vairamani <>
Reviewed-By: Luigi Pinca <>
Reviewed-By: Benjamin Gruenbaum <>
Reviewed-By: Santiago Gimeno <>
Reviewed-By: James M Snell <>
Reviewed-By: Jeremiah Senkpiel <>
  • Loading branch information...
cjihrig committed Apr 19, 2017
1 parent 58066d1 commit 5e095f699e2f7253cd151c0a829dd020c78d2487
Showing with 2 additions and 1 deletion.
  1. +2 −1 test/parallel/test-event-emitter-max-listeners-warning.js
@@ -19,4 +19,5 @@ process.on('warning', common.mustCall((warning) => {

e.on('event-type', common.noop);
e.on('event-type', common.noop);
e.on('event-type', common.noop); // Trigger warning.
e.on('event-type', common.noop); // Verify that warning is emitted only once.

0 comments on commit 5e095f6

Please sign in to comment.
You can’t perform that action at this time.