From 61091bdc1ea5736de68acabd84095ba6932d7b8b Mon Sep 17 00:00:00 2001 From: Ofir Sonsino Date: Mon, 9 Oct 2017 13:25:29 +0300 Subject: Improve SONAR coverage Change-Id: Icdae04aadd50e29a55db559a69495a688ea34b0e Issue-ID: VID-72 Signed-off-by: Ofir Sonsino --- .../vid/aai/model/RelatedToPropertyTest.java | 55 ++++++++++++++++++++++ .../vid/aai/model/RelationshipDataTest.java | 55 ++++++++++++++++++++++ .../org/openecomp/vid/aai/model/TestSuite.java | 2 +- 3 files changed, 111 insertions(+), 1 deletion(-) create mode 100644 vid-app-common/src/test/java/org/openecomp/vid/aai/model/RelatedToPropertyTest.java create mode 100644 vid-app-common/src/test/java/org/openecomp/vid/aai/model/RelationshipDataTest.java (limited to 'vid-app-common/src/test/java/org/openecomp/vid/aai') diff --git a/vid-app-common/src/test/java/org/openecomp/vid/aai/model/RelatedToPropertyTest.java b/vid-app-common/src/test/java/org/openecomp/vid/aai/model/RelatedToPropertyTest.java new file mode 100644 index 00000000..08a87173 --- /dev/null +++ b/vid-app-common/src/test/java/org/openecomp/vid/aai/model/RelatedToPropertyTest.java @@ -0,0 +1,55 @@ +package org.openecomp.vid.aai.model; + +import org.junit.Test; + + +public class RelatedToPropertyTest { + + private RelatedToProperty createTestSubject() { + return new RelatedToProperty(); + } + + + @Test + public void testGetPropertyKey() throws Exception { + RelatedToProperty testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getPropertyKey(); + } + + + @Test + public void testSetPropertyKey() throws Exception { + RelatedToProperty testSubject; + String propertyKey = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setPropertyKey(propertyKey); + } + + + @Test + public void testGetPropertyValue() throws Exception { + RelatedToProperty testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getPropertyValue(); + } + + + @Test + public void testSetPropertyValue() throws Exception { + RelatedToProperty testSubject; + String propertyValue = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setPropertyValue(propertyValue); + } +} \ No newline at end of file diff --git a/vid-app-common/src/test/java/org/openecomp/vid/aai/model/RelationshipDataTest.java b/vid-app-common/src/test/java/org/openecomp/vid/aai/model/RelationshipDataTest.java new file mode 100644 index 00000000..4df27ccd --- /dev/null +++ b/vid-app-common/src/test/java/org/openecomp/vid/aai/model/RelationshipDataTest.java @@ -0,0 +1,55 @@ +package org.openecomp.vid.aai.model; + +import org.junit.Test; + + +public class RelationshipDataTest { + + private RelationshipData createTestSubject() { + return new RelationshipData(); + } + + + @Test + public void testGetRelationshipKey() throws Exception { + RelationshipData testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getRelationshipKey(); + } + + + @Test + public void testSetRelationshipKey() throws Exception { + RelationshipData testSubject; + String relationshipKey = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setRelationshipKey(relationshipKey); + } + + + @Test + public void testGetRelationshipValue() throws Exception { + RelationshipData testSubject; + String result; + + // default test + testSubject = createTestSubject(); + result = testSubject.getRelationshipValue(); + } + + + @Test + public void testSetRelationshipValue() throws Exception { + RelationshipData testSubject; + String relationshipValue = ""; + + // default test + testSubject = createTestSubject(); + testSubject.setRelationshipValue(relationshipValue); + } +} \ No newline at end of file diff --git a/vid-app-common/src/test/java/org/openecomp/vid/aai/model/TestSuite.java b/vid-app-common/src/test/java/org/openecomp/vid/aai/model/TestSuite.java index bb483627..34ca70bd 100644 --- a/vid-app-common/src/test/java/org/openecomp/vid/aai/model/TestSuite.java +++ b/vid-app-common/src/test/java/org/openecomp/vid/aai/model/TestSuite.java @@ -6,6 +6,6 @@ import org.junit.runners.Suite; @RunWith(Suite.class) @Suite.SuiteClasses( -{ ServiceRelationshipsTest.class, RelationshipTest.class }) +{ ServiceRelationshipsTest.class, RelationshipTest.class, RelatedToPropertyTest.class, RelationshipDataTest.class }) public class TestSuite { // nothing } -- cgit 1.2.3-korg