summaryrefslogtreecommitdiffstats
path: root/ONAP-PAP-REST/src/test/java/org/onap/policy/pap/xacml/rest/components/DecisionPolicyTest.java
diff options
context:
space:
mode:
Diffstat (limited to 'ONAP-PAP-REST/src/test/java/org/onap/policy/pap/xacml/rest/components/DecisionPolicyTest.java')
-rw-r--r--ONAP-PAP-REST/src/test/java/org/onap/policy/pap/xacml/rest/components/DecisionPolicyTest.java35
1 files changed, 3 insertions, 32 deletions
diff --git a/ONAP-PAP-REST/src/test/java/org/onap/policy/pap/xacml/rest/components/DecisionPolicyTest.java b/ONAP-PAP-REST/src/test/java/org/onap/policy/pap/xacml/rest/components/DecisionPolicyTest.java
index caa5707cc..e16dd9889 100644
--- a/ONAP-PAP-REST/src/test/java/org/onap/policy/pap/xacml/rest/components/DecisionPolicyTest.java
+++ b/ONAP-PAP-REST/src/test/java/org/onap/policy/pap/xacml/rest/components/DecisionPolicyTest.java
@@ -2,7 +2,7 @@
* ============LICENSE_START=======================================================
* ONAP-PAP-REST
* ================================================================================
- * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * Copyright (C) 2017-2018 AT&T Intellectual Property. 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.
@@ -19,7 +19,6 @@
*/
package org.onap.policy.pap.xacml.rest.components;
-import static org.junit.Assert.*;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
import static org.mockito.Mockito.when;
@@ -30,7 +29,6 @@ import java.util.List;
import java.util.Map;
import java.util.UUID;
-import org.junit.After;
import org.junit.Before;
import org.junit.Test;
import org.mockito.Mockito;
@@ -101,19 +99,12 @@ public class DecisionPolicyTest {
policyAdapter.setRainydayMap(treatmentMap);
policyAdapter.setRainyday(rainyday);
- component = new DecisionPolicy(policyAdapter);
+ component = new DecisionPolicy(policyAdapter, null);
logger.info("setUp: exit");
}
/**
- * @throws java.lang.Exception
- */
- @After
- public void tearDown() throws Exception {
- }
-
- /**
* Test method for {@link org.openecomp.policy.pap.xacml.rest.components.DecisionPolicy#savePolicies()}.
*/
@Test
@@ -140,25 +131,7 @@ public class DecisionPolicyTest {
public void testPrepareToSaveRainyDay() {
logger.debug("test PrepareToSave Policy: enter");
policyAdapter.setRuleProvider("Rainy_Day");
- component = new DecisionPolicy(policyAdapter);
- boolean response = false;
-
- try {
- response = component.prepareToSave();
- } catch (Exception e) {
- logger.error("Exception Occured"+e);
- }
- assertTrue(response);
- }
-
- /**
- * Test method for {@link org.openecomp.policy.pap.xacml.rest.components.DecisionPolicy#prepareToSave()}.
- */
- @Test
- public void testPrepareToSaveCustom() {
- logger.debug("test PrepareToSave Policy: enter");
- policyAdapter.setRuleProvider("Custom");
- component = new DecisionPolicy(policyAdapter);
+ component = new DecisionPolicy(policyAdapter, null);
boolean response = false;
try {
@@ -168,6 +141,4 @@ public class DecisionPolicyTest {
}
assertTrue(response);
}
-
-
} \ No newline at end of file