From 273778c96c32cf093b99f1118cc01187192d2b96 Mon Sep 17 00:00:00 2001 From: Norman Maurer Date: Mon, 10 Oct 2016 14:33:21 +0200 Subject: [PATCH] Correctly add futures to list in test Motivation: We missed to add the futures to the list in the test. Modifications: Add futures to list. Result: More correct test. --- .../util/concurrent/NonStickyEventExecutorGroupTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/common/src/test/java/io/netty/util/concurrent/NonStickyEventExecutorGroupTest.java b/common/src/test/java/io/netty/util/concurrent/NonStickyEventExecutorGroupTest.java index 009aec9e10..5582a049da 100644 --- a/common/src/test/java/io/netty/util/concurrent/NonStickyEventExecutorGroupTest.java +++ b/common/src/test/java/io/netty/util/concurrent/NonStickyEventExecutorGroupTest.java @@ -104,7 +104,7 @@ public class NonStickyEventExecutorGroupTest { for (int i = 1 ; i <= tasks; i++) { final int id = i; - executor.execute(new Runnable() { + futures.add(executor.submit(new Runnable() { @Override public void run() { try { @@ -122,7 +122,7 @@ public class NonStickyEventExecutorGroupTest { latch.countDown(); } } - }); + })); } latch.await(); for (Future future: futures) {