From 041017a10245054de9d32e9dceefdafef3e694ac Mon Sep 17 00:00:00 2001 From: Jim Hahn Date: Fri, 20 Mar 2020 17:17:00 -0400 Subject: Remove vLB from drools-apps Added a test for legacy policy to vDNS. Issue-ID: POLICY-2434 Signed-off-by: Jim Hahn Change-Id: I92fc7813067d3e98562e5d1c7f0da7afe5aac96d --- .../common/rules/test/BaseRuleTest.java | 43 ++++++++-------------- 1 file changed, 15 insertions(+), 28 deletions(-) (limited to 'controlloop/common/rules-test/src/main/java') diff --git a/controlloop/common/rules-test/src/main/java/org/onap/policy/controlloop/common/rules/test/BaseRuleTest.java b/controlloop/common/rules-test/src/main/java/org/onap/policy/controlloop/common/rules/test/BaseRuleTest.java index f8b033ca0..c582ecebe 100644 --- a/controlloop/common/rules-test/src/main/java/org/onap/policy/controlloop/common/rules/test/BaseRuleTest.java +++ b/controlloop/common/rules-test/src/main/java/org/onap/policy/controlloop/common/rules/test/BaseRuleTest.java @@ -46,6 +46,7 @@ import org.onap.policy.models.tosca.authorative.concepts.ToscaPolicy; */ public abstract class BaseRuleTest { private static final String APPC_RESTART_OP = "restart"; + private static final String APPC_MODIFY_CONFIG_OP = "ModifyConfig"; /* * Canonical Topic Names. @@ -82,6 +83,7 @@ public abstract class BaseRuleTest { private static final String VCPE_APPC_SUCCESS = "vcpe/vcpe.appc.success.json"; // VDNS + private static final String VDNS_TOSCA_LEGACY_POLICY = "vdns/tosca-legacy-vdns.json"; private static final String VDNS_TOSCA_COMPLIANT_POLICY = "vdns/tosca-compliant-vdns.json"; private static final String VDNS_ONSET = "vdns/vdns.onset.json"; @@ -93,11 +95,6 @@ public abstract class BaseRuleTest { private static final String VFW_APPC_SUCCESS = "vfw/vfw.appc.success.json"; private static final String VFW_APPC_FAILURE = "vfw/vfw.appc.failure.json"; - // VLB - private static final String VLB_TOSCA_LEGACY_POLICY = "vlb/tosca-vlb.json"; - private static final String VLB_TOSCA_COMPLIANT_POLICY = "vlb/tosca-compliant-vlb.json"; - private static final String VLB_ONSET = "vlb/vlb.onset.json"; - /* * Coders used to decode requests and responses. */ @@ -298,6 +295,14 @@ public abstract class BaseRuleTest { // VDNS + /** + * Sunny Day with Legacy Tosca Policy. + */ + @Test + public void testVdnsSunnyDayLegacy() { + httpSunnyDay(VDNS_TOSCA_LEGACY_POLICY, VDNS_ONSET); + } + /** * Sunny Day with Tosca Compliant Policy. */ @@ -313,7 +318,7 @@ public abstract class BaseRuleTest { */ @Test public void testVfwSunnyDayLegacy() { - appcLegacySunnyDay(VFW_TOSCA_LEGACY_POLICY, VFW_ONSET, "ModifyConfig"); + appcLegacySunnyDay(VFW_TOSCA_LEGACY_POLICY, VFW_ONSET, APPC_MODIFY_CONFIG_OP); } /** @@ -321,7 +326,7 @@ public abstract class BaseRuleTest { */ @Test public void testVfwSunnyDayCompliant() { - appcLegacySunnyDay(VFW_TOSCA_COMPLIANT_POLICY, VFW_ONSET, "ModifyConfig"); + appcLegacySunnyDay(VFW_TOSCA_COMPLIANT_POLICY, VFW_ONSET, APPC_MODIFY_CONFIG_OP); } /** @@ -329,7 +334,7 @@ public abstract class BaseRuleTest { */ @Test public void testVfwRainyDayLegacyFailure() { - appcLegacyRainyDay(VFW_TOSCA_LEGACY_POLICY, VFW_ONSET, "ModifyConfig"); + appcLegacyRainyDay(VFW_TOSCA_LEGACY_POLICY, VFW_ONSET, APPC_MODIFY_CONFIG_OP); } /** @@ -337,7 +342,7 @@ public abstract class BaseRuleTest { */ @Test public void testVfwRainyDayOverallTimeout() { - appcLegacyRainyDayNoResponse(VFW_TOSCA_COMPLIANT_TIME_OUT_POLICY, VFW_ONSET, "ModifyConfig"); + appcLegacyRainyDayNoResponse(VFW_TOSCA_COMPLIANT_TIME_OUT_POLICY, VFW_ONSET, APPC_MODIFY_CONFIG_OP); } /** @@ -345,25 +350,7 @@ public abstract class BaseRuleTest { */ @Test public void testVfwRainyDayCompliantTimeout() { - appcLegacyRainyDayNoResponse(VFW_TOSCA_COMPLIANT_POLICY, VFW_ONSET, "ModifyConfig"); - } - - // VLB - - /** - * Sunny Day with Legacy Tosca Policy. - */ - @Test - public void testVlbSunnyDayLegacy() { - httpSunnyDay(VLB_TOSCA_LEGACY_POLICY, VLB_ONSET); - } - - /** - * Sunny Day with Tosca Compliant Policy. - */ - @Test - public void testVlbSunnyDayCompliant() { - httpSunnyDay(VLB_TOSCA_COMPLIANT_POLICY, VLB_ONSET); + appcLegacyRainyDayNoResponse(VFW_TOSCA_COMPLIANT_POLICY, VFW_ONSET, APPC_MODIFY_CONFIG_OP); } /** -- cgit 1.2.3-korg