diff options
author | Jim Hahn <jrh3@att.com> | 2020-02-17 22:25:03 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2020-02-17 22:25:03 +0000 |
commit | 85a2fee4074903012e77f78e26328b9a03a8bdfc (patch) | |
tree | e4c281ec3d174150a62bbb640ba7883aef23fd0e /models-interactions/model-actors/actor.sdnc/src/test | |
parent | 22e831dbd5820b54bb24131e007190b70e3321d4 (diff) | |
parent | 28ca4d196bb0e8c50ad64b5bfde117a93ace3e04 (diff) |
Merge "Use BidirectionalTopicClient from policy-common"
Diffstat (limited to 'models-interactions/model-actors/actor.sdnc/src/test')
-rw-r--r-- | models-interactions/model-actors/actor.sdnc/src/test/java/org/onap/policy/controlloop/actor/sdnc/BasicSdncOperator.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/models-interactions/model-actors/actor.sdnc/src/test/java/org/onap/policy/controlloop/actor/sdnc/BasicSdncOperator.java b/models-interactions/model-actors/actor.sdnc/src/test/java/org/onap/policy/controlloop/actor/sdnc/BasicSdncOperator.java index d8c707cc3..deafc4e9d 100644 --- a/models-interactions/model-actors/actor.sdnc/src/test/java/org/onap/policy/controlloop/actor/sdnc/BasicSdncOperator.java +++ b/models-interactions/model-actors/actor.sdnc/src/test/java/org/onap/policy/controlloop/actor/sdnc/BasicSdncOperator.java @@ -23,6 +23,7 @@ package org.onap.policy.controlloop.actor.sdnc; import static org.assertj.core.api.Assertions.assertThatIllegalArgumentException; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertTrue; import static org.mockito.ArgumentMatchers.any; import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; @@ -30,7 +31,6 @@ import static org.mockito.Mockito.when; import java.util.Map; import java.util.concurrent.CompletableFuture; import java.util.concurrent.ExecutionException; -import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeoutException; import java.util.function.BiFunction; import org.onap.policy.common.utils.coder.CoderException; @@ -100,7 +100,10 @@ public abstract class BasicSdncOperator extends BasicHttpOperation<SdncRequest> verify(client).post(callbackCaptor.capture(), any(), requestCaptor.capture(), any()); callbackCaptor.getValue().completed(rawResponse); - assertEquals(PolicyResult.SUCCESS, future2.get(5, TimeUnit.SECONDS).getResult()); + executor.runAll(100); + assertTrue(future2.isDone()); + + assertEquals(PolicyResult.SUCCESS, future2.get().getResult()); return requestCaptor.getValue().getEntity(); } |