You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by re...@apache.org on 2021/01/06 22:58:56 UTC

[cxf] 01/02: CXF-8395: Fix org.apache.cxf.workqueue.AutomaticWorkQueueTest.testEnqueueImmediate

This is an automated email from the ASF dual-hosted git repository.

reta pushed a commit to branch 3.4.x-fixes
in repository https://gitbox.apache.org/repos/asf/cxf.git

commit 26c857ade6e3676aea3b64710c4beafda1ec0c57
Author: reta <dr...@gmail.com>
AuthorDate: Tue Jan 5 22:39:35 2021 -0500

    CXF-8395: Fix org.apache.cxf.workqueue.AutomaticWorkQueueTest.testEnqueueImmediate
    
    (cherry picked from commit f4b77a454c6affe9ae42f6060382a2412ab4f0cc)
---
 core/src/test/java/org/apache/cxf/workqueue/AutomaticWorkQueueTest.java | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/core/src/test/java/org/apache/cxf/workqueue/AutomaticWorkQueueTest.java b/core/src/test/java/org/apache/cxf/workqueue/AutomaticWorkQueueTest.java
index c13698c..f40f42c 100644
--- a/core/src/test/java/org/apache/cxf/workqueue/AutomaticWorkQueueTest.java
+++ b/core/src/test/java/org/apache/cxf/workqueue/AutomaticWorkQueueTest.java
@@ -176,6 +176,8 @@ public class AutomaticWorkQueueTest {
                 workItems[i] = new BlockingWorkItem();
                 try {
                     workqueue.execute(workItems[i]);
+                    //wait some time to allow worker to be created and work to be assigned
+                    Thread.sleep(100L);
                 } catch (RejectedExecutionException ex) {
                     fail("failed on item[" + i + "] with: " + ex);
                 }