From 1c2dcbb8e38fe1e3f3271dade73a7b3a7c3a64b5 Mon Sep 17 00:00:00 2001 From: daniel Date: Wed, 4 Oct 2017 10:09:37 -0500 Subject: Fix JUnit Race Conditions This fix now implements the observer pattern for the PolicyEngineJUnitImpl so that the test cases can be notified when an event is available to be pulled. This eliminates the need to sleep the thread for some arbitrary time to let the rules process events. Issue-ID: POLICY-291 Change-Id: I884c959c20b95a1b58f357602099d8a01c8d2e3c Signed-off-by: Daniel Cruz --- .../src/test/resources/yaml/policy_ControlLoop_vCPE.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'controlloop/templates/template.demo/src/test/resources/yaml/policy_ControlLoop_vCPE.yaml') diff --git a/controlloop/templates/template.demo/src/test/resources/yaml/policy_ControlLoop_vCPE.yaml b/controlloop/templates/template.demo/src/test/resources/yaml/policy_ControlLoop_vCPE.yaml index de2ece4ed..65a3a4f8b 100644 --- a/controlloop/templates/template.demo/src/test/resources/yaml/policy_ControlLoop_vCPE.yaml +++ b/controlloop/templates/template.demo/src/test/resources/yaml/policy_ControlLoop_vCPE.yaml @@ -2,7 +2,7 @@ controlLoop: version: 2.0.0 controlLoopName: ControlLoop-vCPE-48f0c2c3-a172-4192-9ae3-052274181b6e trigger_policy: unique-policy-id-1-restart - timeout: 3600 + timeout: 20 abatement: true policies: @@ -14,7 +14,7 @@ policies: target: type: VM retry: 3 - timeout: 1200 + timeout: 10 success: final_success failure: final_failure failure_timeout: final_failure_timeout -- cgit 1.2.3-korg