martinweiler commented on code in PR #4164:
URL: 
https://github.com/apache/incubator-kie-kogito-runtimes/pull/4164#discussion_r2737887957


##########
quarkus/integration-tests/integration-tests-quarkus-wshumantasks/src/test/java/org/jbpm/usertask/jpa/it/WsHumanTaskLifeCycleIT.java:
##########
@@ -206,7 +206,291 @@ public void testSuspendAndResumeTransition() {
 
         complete(taskId, user);
 
-        isProcessCompleted(processId);
+        isProcessCompleted(processId, pid);
+    }
+
+    @Test
+    public void testSuspendUntilWithDuration() throws InterruptedException {
+        var user = "dave";
+        var potentialUsers = new String[] { "john", "dave" };
+        var processId = "manager_multiple_users";
+        var pid = startProcessInstance(processId);
+        var taskId = getTaskId(user, pid);
+        verifyTask(processId, pid, taskId, user, "Ready", potentialUsers);
+
+        suspendWithDurationOrTimestamp(taskId, user, "PT5S");
+        Thread.sleep(10000);

Review Comment:
   For all these tests, can we try to minimize the execution time?
   * `PT1S` instead of `PT5S`
   * Remove `Thread.sleep(..)`
   * Replace with something like the following in the `verifyTaskStatus` method:
   ```
   await().atMost(Duration.ofSeconds(5))
                   .untilAsserted(() -> given() ....
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to