summaryrefslogtreecommitdiffstats
path: root/src/test/java
diff options
context:
space:
mode:
authorJennie Jia <Jennie.Jia@amdocs.com>2018-09-13 02:36:10 +0000
committerJennie Jia <Jennie.Jia@amdocs.com>2018-09-13 17:32:54 +0000
commitbf4b8e3ac93106cf2373dafb89d5373fc17ef507 (patch)
tree58457c0cc0be0b3b72958cdd7dccc95dd401208d /src/test/java
parent5a34dbbd091db590a9a38e5398140933ae9ed639 (diff)
Handle Missing AAI Data
Issue-ID: LOG-649 Change-Id: Ie393ac995ef6b4d8c8d819d8c4815be3acab579c Signed-off-by: Jennie Jia <Jennie.Jia@amdocs.com>
Diffstat (limited to 'src/test/java')
-rw-r--r--src/test/java/org/onap/logging_analytics/pomba/pomba_aai_context_builder/RestUtilTest.java30
1 files changed, 2 insertions, 28 deletions
diff --git a/src/test/java/org/onap/logging_analytics/pomba/pomba_aai_context_builder/RestUtilTest.java b/src/test/java/org/onap/logging_analytics/pomba/pomba_aai_context_builder/RestUtilTest.java
index 8b3fe63..ad8193a 100644
--- a/src/test/java/org/onap/logging_analytics/pomba/pomba_aai_context_builder/RestUtilTest.java
+++ b/src/test/java/org/onap/logging_analytics/pomba/pomba_aai_context_builder/RestUtilTest.java
@@ -65,43 +65,17 @@ public class RestUtilTest {
public void testValidateURL() {
// Missing ServiceInstanceId or it is null
try {
- RestUtil.validateURL("", "modelVersionId", "modelInvariantId");
+ RestUtil.validateURL("");
} catch (AuditException e) {
assertTrue(e.getMessage().contains("Invalid request URL, missing parameter: serviceInstanceId"));
}
try {
- RestUtil.validateURL(null, "modelVersionId", "modelInvariantId");
+ RestUtil.validateURL(null);
} catch (AuditException e) {
assertTrue(e.getMessage().contains("Invalid request URL, missing parameter: serviceInstanceId"));
}
- // Missing ModelVersionId or it is null
- try {
- RestUtil.validateURL("serviceInstanceId", "", "modelInvariantId");
- } catch (AuditException e) {
- assertTrue(e.getMessage().contains("Invalid request URL, missing parameter: modelVersionId"));
- }
-
- try {
- RestUtil.validateURL("serviceInstanceId", null, "modelInvariantId");
- } catch (AuditException e) {
- assertTrue(e.getMessage().contains("Invalid request URL, missing parameter: modelVersionId"));
- }
-
- // Missing ModelInvariantId or it is null
- try {
- RestUtil.validateURL("serviceInstanceId", "modelVersionId", "");
- } catch (AuditException e) {
- assertTrue(e.getMessage().contains("Invalid request URL, missing parameter: modelInvariantId"));
- }
-
- try {
- RestUtil.validateURL("serviceInstanceId", "modelVersionId", null);
- } catch (AuditException e) {
- assertTrue(e.getMessage().contains("Invalid request URL, missing parameter: modelInvariantId"));
- }
-
}
@Test