summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDeterme, Sebastien (sd378r) <sd378r@intl.att.com>2017-09-22 15:43:16 +0200
committerDeterme, Sebastien (sd378r) <sd378r@intl.att.com>2017-09-22 16:04:02 +0200
commit8f40b5d7e635859160833568d158d631eb6857dd (patch)
tree8ef53711570e55851ab8f77500a5ec8f01de5c70 /src
parentc520a27acebee8005dd84f07510c3862155aca86 (diff)
Rename a test class
Rename a test class by using the name of the class tested Change-Id: Ic2dc993ec874872b3acc9ef95fdfdb540ff61742 Issue-ID: CLAMP-54 Signed-off-by: Determe, Sebastien (sd378r) <sd378r@intl.att.com>
Diffstat (limited to 'src')
-rw-r--r--src/test/java/org/onap/clamp/clds/client/req/OperationalPolicyReqTest.java (renamed from src/test/java/org/onap/clamp/clds/client/req/SdcPolicyReqTest.java)8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/test/java/org/onap/clamp/clds/client/req/SdcPolicyReqTest.java b/src/test/java/org/onap/clamp/clds/client/req/OperationalPolicyReqTest.java
index c2d9ae466..cf1fc98e9 100644
--- a/src/test/java/org/onap/clamp/clds/client/req/SdcPolicyReqTest.java
+++ b/src/test/java/org/onap/clamp/clds/client/req/OperationalPolicyReqTest.java
@@ -35,7 +35,7 @@ import org.onap.policy.asdc.Resource;
import org.onap.policy.asdc.ResourceType;
import org.onap.policy.controlloop.policy.PolicyResult;
-public class SdcPolicyReqTest {
+public class OperationalPolicyReqTest {
@Test
public void convertToResourceTest() throws NoSuchMethodException, SecurityException, IllegalAccessException,
@@ -44,13 +44,12 @@ public class SdcPolicyReqTest {
ResourceType.class);
method.setAccessible(true);
// return method.invoke(targetObject, argObjects);
- OperationalPolicyReq policyReq = new OperationalPolicyReq();
List<String> stringList = new ArrayList<>();
stringList.add("test1");
stringList.add("test2");
stringList.add("test3");
stringList.add("test4");
- Resource resources[] = (Resource[]) method.invoke(policyReq, stringList, ResourceType.VF);
+ Resource resources[] = (Resource[]) method.invoke(null, stringList, ResourceType.VF);
assertTrue(resources.length == 4);
assertTrue("test1".equals(resources[0].getResourceName()));
@@ -65,13 +64,12 @@ public class SdcPolicyReqTest {
Method method = OperationalPolicyReq.class.getDeclaredMethod("convertToPolicyResult", List.class);
method.setAccessible(true);
// return method.invoke(targetObject, argObjects);
- OperationalPolicyReq policyReq = new OperationalPolicyReq();
List<String> stringList = new ArrayList<>();
stringList.add("FAILURE");
stringList.add("SUCCESS");
stringList.add("FAILURE_GUARD");
stringList.add("FAILURE_TIMEOUT");
- PolicyResult policyResult[] = (PolicyResult[]) method.invoke(policyReq, stringList);
+ PolicyResult policyResult[] = (PolicyResult[]) method.invoke(null, stringList);
assertTrue(policyResult.length == 4);
assertTrue(policyResult[0].equals(PolicyResult.FAILURE));