diff --git a/Kitodo/src/test/java/org/kitodo/production/services/command/CommandServiceTest.java b/Kitodo/src/test/java/org/kitodo/production/services/command/CommandServiceTest.java index 98c42861b7c..a1356f55c2d 100644 --- a/Kitodo/src/test/java/org/kitodo/production/services/command/CommandServiceTest.java +++ b/Kitodo/src/test/java/org/kitodo/production/services/command/CommandServiceTest.java @@ -158,7 +158,7 @@ public void runNotExistingScriptAsync() throws InterruptedException { String commandString = scriptPath + "not_existing_script" + scriptExtension; CommandService service = new CommandService(); service.runCommandAsync(commandString); - Thread.sleep(1000); // wait for async thread to finish; + Thread.sleep(2000); // wait for async thread to finish; CommandResult result = getLastFinishedCommandResult(service.getFinishedCommandResults()); assertNotNull("There were no results!", result); assertTrue("result message should contain IOException", @@ -173,7 +173,7 @@ public void runScriptParametersAsync() throws InterruptedException { parameter.add("HelloWorld"); CommandService service = new CommandService(); service.runCommandAsync(file, parameter); - Thread.sleep(1000); // wait for async thread to finish; + Thread.sleep(2000); // wait for async thread to finish; CommandResult result = getLastFinishedCommandResult(service.getFinishedCommandResults()); ArrayList expectedMessages = new ArrayList<>();