From 54d868eb5750f87506d74067d8e0ef8734015502 Mon Sep 17 00:00:00 2001 From: Charles Cole Date: Wed, 13 Sep 2017 11:00:21 -0500 Subject: Modify AAI simulator to support new requests Updated the AAI simulator to support new AAI queries. Also, modified the post response to allow multiple responses. Added code to ensure the simulators were able to sucessfully start up. Change-Id: I3e855b5e54c073f55fbaadc0064c140695fc1a58 Issue-ID: POLICY-200 Signed-off-by: Charles Cole --- .../org/onap/policy/template/demo/ControlLoopXacmlGuardTest.java | 2 +- .../src/test/java/org/onap/policy/template/demo/TestSO.java | 2 +- .../src/test/java/org/onap/policy/template/demo/Util.java | 6 +++--- .../java/org/onap/policy/template/demo/VDNSControlLoopTest.java | 2 +- .../test/java/org/onap/policy/template/demo/VFWControlLoopTest.java | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) (limited to 'controlloop/templates') diff --git a/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/ControlLoopXacmlGuardTest.java b/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/ControlLoopXacmlGuardTest.java index d1fa4fc10..64ad490b2 100644 --- a/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/ControlLoopXacmlGuardTest.java +++ b/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/ControlLoopXacmlGuardTest.java @@ -60,7 +60,7 @@ public class ControlLoopXacmlGuardTest { public static void setUpSimulator() { try { Util.buildAaiSim(); - } catch (InterruptedException e) { + } catch (Exception e) { fail(e.getMessage()); } } diff --git a/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/TestSO.java b/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/TestSO.java index 16ad7a8b0..08f73f4bc 100644 --- a/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/TestSO.java +++ b/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/TestSO.java @@ -71,7 +71,7 @@ public class TestSO { try { Util.buildAaiSim(); Util.buildSoSim(); - } catch (InterruptedException e) { + } catch (Exception e) { fail(e.getMessage()); } } diff --git a/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/Util.java b/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/Util.java index 5a96e1667..715b8f795 100644 --- a/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/Util.java +++ b/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/Util.java @@ -113,15 +113,15 @@ public final class Util { return null; } - public static HttpServletServer buildAaiSim() throws InterruptedException { + public static HttpServletServer buildAaiSim() throws InterruptedException, IOException { return org.onap.policy.simulators.Util.buildAaiSim(); } - public static HttpServletServer buildSoSim() throws InterruptedException { + public static HttpServletServer buildSoSim() throws InterruptedException, IOException { return org.onap.policy.simulators.Util.buildSoSim(); } - public static HttpServletServer buildVfcSim() throws InterruptedException { + public static HttpServletServer buildVfcSim() throws InterruptedException, IOException { return org.onap.policy.simulators.Util.buildVfcSim(); } diff --git a/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/VDNSControlLoopTest.java b/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/VDNSControlLoopTest.java index e107e2e7c..9608f7cf0 100644 --- a/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/VDNSControlLoopTest.java +++ b/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/VDNSControlLoopTest.java @@ -63,7 +63,7 @@ public class VDNSControlLoopTest { try { Util.buildAaiSim(); Util.buildSoSim(); - } catch (InterruptedException e) { + } catch (Exception e) { fail(e.getMessage()); } } diff --git a/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/VFWControlLoopTest.java b/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/VFWControlLoopTest.java index 49cbf5227..a19d9267c 100644 --- a/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/VFWControlLoopTest.java +++ b/controlloop/templates/template.demo/src/test/java/org/onap/policy/template/demo/VFWControlLoopTest.java @@ -60,7 +60,7 @@ public class VFWControlLoopTest { public static void setUpSimulator() { try { Util.buildAaiSim(); - } catch (InterruptedException e) { + } catch (Exception e) { fail(e.getMessage()); } } -- cgit 1.2.3-korg