Added a delai for the task initialization

Signed-off-by: Emmanuel Bigeon <emmanuel@bigeon.fr>
This commit is contained in:
Emmanuel Bigeon 2018-11-30 22:56:51 -05:00
parent 6443790532
commit b671474f64

View File

@ -46,6 +46,12 @@ public class ForkTaskTest {
final Thread execThread = new Thread(task); final Thread execThread = new Thread(task);
execThread.start(); execThread.start();
try {
execThread.join(100);
} catch (final InterruptedException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
try (PipedConsoleOutput pco = new PipedConsoleOutput(); try (PipedConsoleOutput pco = new PipedConsoleOutput();
PipedConsoleInput pci = new PipedConsoleInput(null)) { PipedConsoleInput pci = new PipedConsoleInput(null)) {