diff options
Diffstat (limited to 'services/services-onappf/src/test/java')
2 files changed, 8 insertions, 6 deletions
diff --git a/services/services-onappf/src/test/java/org/onap/policy/apex/services/onappf/comm/TestPdpStateChangeListener.java b/services/services-onappf/src/test/java/org/onap/policy/apex/services/onappf/comm/TestPdpStateChangeListener.java index 17f909fcc..1d491ea03 100644 --- a/services/services-onappf/src/test/java/org/onap/policy/apex/services/onappf/comm/TestPdpStateChangeListener.java +++ b/services/services-onappf/src/test/java/org/onap/policy/apex/services/onappf/comm/TestPdpStateChangeListener.java @@ -2,6 +2,7 @@ * ============LICENSE_START======================================================= * Copyright (C) 2019-2020 Nordix Foundation. * Modifications Copyright (C) 2019 AT&T Intellectual Property. All rights reserved. + * Modifications Copyright (C) 2020 Bell Canada. All rights reserved. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -156,7 +157,7 @@ public class TestPdpStateChangeListener { assertTrue(outContent.toString().contains("State changed to active. No policies found.")); final ToscaPolicy toscaPolicy = - TestListenerUtils.createToscaPolicy("apex policy name", "1.0", "src/test/resources/dummyProperties.json"); + TestListenerUtils.createToscaPolicy("apex_policy_name", "1.0", "src/test/resources/dummyProperties.json"); final List<ToscaPolicy> toscaPolicies = new ArrayList<ToscaPolicy>(); toscaPolicies.add(toscaPolicy); final PdpUpdate pdpUpdateMsg = TestListenerUtils.createPdpUpdateMsg(pdpStatus, toscaPolicies); @@ -179,7 +180,7 @@ public class TestPdpStateChangeListener { public void testPdpStateChangeMessageListener_activetopassive() throws InterruptedException, CoderException { final PdpStatus pdpStatus = Registry.get(ApexStarterConstants.REG_PDP_STATUS_OBJECT); final ToscaPolicy toscaPolicy = - TestListenerUtils.createToscaPolicy("apex policy name", "1.0", "src/test/resources/dummyProperties.json"); + TestListenerUtils.createToscaPolicy("apex_policy_name", "1.0", "src/test/resources/dummyProperties.json"); final List<ToscaPolicy> toscaPolicies = new ArrayList<ToscaPolicy>(); toscaPolicies.add(toscaPolicy); final PdpUpdate pdpUpdateMsg = TestListenerUtils.createPdpUpdateMsg(pdpStatus, toscaPolicies); diff --git a/services/services-onappf/src/test/java/org/onap/policy/apex/services/onappf/comm/TestPdpUpdateListener.java b/services/services-onappf/src/test/java/org/onap/policy/apex/services/onappf/comm/TestPdpUpdateListener.java index 05656af96..d9b8fc09c 100644 --- a/services/services-onappf/src/test/java/org/onap/policy/apex/services/onappf/comm/TestPdpUpdateListener.java +++ b/services/services-onappf/src/test/java/org/onap/policy/apex/services/onappf/comm/TestPdpUpdateListener.java @@ -2,6 +2,7 @@ * ============LICENSE_START======================================================= * Copyright (C) 2019 Nordix Foundation. * Modifications Copyright (C) 2019 AT&T Intellectual Property. All rights reserved. + * Modifications Copyright (C) 2020 Bell Canada. All rights reserved. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -142,7 +143,7 @@ public class TestPdpUpdateListener { TestListenerUtils.createPdpStateChangeMsg(PdpState.ACTIVE, "pdpGroup", "pdpSubgroup", pdpStatus.getName()); pdpStateChangeListener.onTopicEvent(INFRA, TOPIC, null, pdpStateChangeMsg); final ToscaPolicy toscaPolicy = - TestListenerUtils.createToscaPolicy("apex policy name", "1.0", "src/test/resources/dummyProperties.json"); + TestListenerUtils.createToscaPolicy("apex_policy_name", "1.0", "src/test/resources/dummyProperties.json"); final List<ToscaPolicy> toscaPolicies = new ArrayList<ToscaPolicy>(); toscaPolicies.add(toscaPolicy); final PdpUpdate pdpUpdateMsg = TestListenerUtils.createPdpUpdateMsg(pdpStatus, toscaPolicies); @@ -164,7 +165,7 @@ public class TestPdpUpdateListener { TestListenerUtils.createPdpStateChangeMsg(PdpState.ACTIVE, "pdpGroup", "pdpSubgroup", pdpStatus.getName()); pdpStateChangeListener.onTopicEvent(INFRA, TOPIC, null, pdpStateChangeMsg); final ToscaPolicy toscaPolicy = - TestListenerUtils.createToscaPolicy("apex policy name", "1.0", "src/test/resources/dummyProperties.json"); + TestListenerUtils.createToscaPolicy("apex_policy_name", "1.0", "src/test/resources/dummyProperties.json"); final List<ToscaPolicy> toscaPolicies = new ArrayList<ToscaPolicy>(); toscaPolicies.add(toscaPolicy); final PdpUpdate pdpUpdateMsg = TestListenerUtils.createPdpUpdateMsg(pdpStatus, toscaPolicies); @@ -185,7 +186,7 @@ public class TestPdpUpdateListener { System.setOut(new PrintStream(outContent)); final PdpStatus pdpStatus = Registry.get(ApexStarterConstants.REG_PDP_STATUS_OBJECT); final ToscaPolicy toscaPolicy = - TestListenerUtils.createToscaPolicy("apex policy name", "1.0", "src/test/resources/dummyProperties.json"); + TestListenerUtils.createToscaPolicy("apex_policy_name", "1.0", "src/test/resources/dummyProperties.json"); final ToscaPolicy toscaPolicy2 = TestListenerUtils.createToscaPolicy("apexpolicy2", "1.0", "src/test/resources/dummyProperties.json"); final List<ToscaPolicy> toscaPolicies = new ArrayList<ToscaPolicy>(); @@ -198,7 +199,7 @@ public class TestPdpUpdateListener { pdpStateChangeListener.onTopicEvent(INFRA, TOPIC, null, pdpStateChangeMsg); final String outString = outContent.toString(); assertTrue(outString.contains( - "Apex engine started. But, only the following polices are running - apex policy name:1.0 . " + "Apex engine started. But, only the following polices are running - apex_policy_name:1.0 . " + "Other policies failed execution. Please see the logs for more details.")); } } |