From 4781f3e75a2dcc2b23f0c77c4f52fdb5b2f0cdf8 Mon Sep 17 00:00:00 2001 From: ezhil Date: Wed, 6 May 2020 15:20:53 +0530 Subject: Junit for RelationshipList Issue-ID: USECASEUI-439 Change-Id: Ibbd60c49d66a21f2a64abb766d2c35fdf79acd63 Signed-off-by: ezhil --- .../lcm/domain/aai/bean/RelationshipListTest.java | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/server/src/test/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/RelationshipListTest.java b/server/src/test/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/RelationshipListTest.java index 48a47a38..fe4ad627 100644 --- a/server/src/test/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/RelationshipListTest.java +++ b/server/src/test/java/org/onap/usecaseui/server/service/lcm/domain/aai/bean/RelationshipListTest.java @@ -2,6 +2,9 @@ package org.onap.usecaseui.server.service.lcm.domain.aai.bean; import org.junit.After; import org.junit.Before; +import org.junit.Test; + +import static org.junit.Assert.assertNotNull; /** * Copyright (C) 2020 Huawei, Inc. and others. All rights reserved. @@ -28,11 +31,26 @@ public class RelationshipListTest { public void after() throws Exception { } + @Test public void relationshipListTest() throws Exception { RelationshipList relationshipList = new RelationshipList(); + Relationship relationship = new Relationship(); + RelationshipData relationshipData = new RelationshipData(); + + relationshipData.setRelationshipKey("123"); + relationshipData.setRelationshipValue("123"); + + relationship.setRelatedLink("123"); + relationship.setRelatedTo("123"); + relationship.setRelationshipLabel("123"); + + RelationshipData[] rd=new RelationshipData[]{relationshipData}; + relationship.setRelationshipData(rd); - relationshipList.getRelationship(); + Relationship[] rslist=new Relationship[]{relationship}; + relationshipList.setRelationship(rslist); + assertNotNull(relationshipList.getRelationship()); } -- cgit 1.2.3-korg