summaryrefslogtreecommitdiffstats
path: root/main/src/test/java/org
diff options
context:
space:
mode:
authorJorge Hernandez <jorge.hernandez-herrero@att.com>2019-03-16 14:51:45 +0000
committerGerrit Code Review <gerrit@onap.org>2019-03-16 14:51:45 +0000
commitda890b5252f08b59b9d8c6441188cc44bbda5b28 (patch)
tree6ec0fdbf9562b6d191232c982425824f01793928 /main/src/test/java/org
parentedbfc1a7994c28282873dbf8326c56b22c78d5a1 (diff)
parentd51dde65937908d97ad057d1ebb2de9993ee6ed3 (diff)
Merge "Add additional constructors to Exception classes"
Diffstat (limited to 'main/src/test/java/org')
-rw-r--r--main/src/test/java/org/onap/policy/pap/main/TestExceptions.java17
1 files changed, 7 insertions, 10 deletions
diff --git a/main/src/test/java/org/onap/policy/pap/main/TestExceptions.java b/main/src/test/java/org/onap/policy/pap/main/TestExceptions.java
index b45cdab7..9e3cda9c 100644
--- a/main/src/test/java/org/onap/policy/pap/main/TestExceptions.java
+++ b/main/src/test/java/org/onap/policy/pap/main/TestExceptions.java
@@ -1,6 +1,7 @@
-/*-
+/*
* ============LICENSE_START=======================================================
* Copyright (C) 2019 Nordix Foundation.
+ * Modifications Copyright (C) 2019 AT&T Intellectual Property.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -20,11 +21,10 @@
package org.onap.policy.pap.main;
-import static org.junit.Assert.assertNotNull;
-
-import java.io.IOException;
-
import org.junit.Test;
+import org.onap.policy.common.utils.test.ExceptionsTester;
+import org.onap.policy.pap.main.PolicyPapException;
+import org.onap.policy.pap.main.PolicyPapRuntimeException;
/**
* Class to perform unit test of {@link PolicyPapException PolicyPapRuntimeException}}.
@@ -35,10 +35,7 @@ public class TestExceptions {
@Test
public void test() {
- assertNotNull(new PolicyPapException("Message"));
- assertNotNull(new PolicyPapException("Message", new IOException()));
-
- assertNotNull(new PolicyPapRuntimeException("Message"));
- assertNotNull(new PolicyPapRuntimeException("Message", new IOException()));
+ new ExceptionsTester().test(PolicyPapException.class);
+ new ExceptionsTester().test(PolicyPapRuntimeException.class);
}
}