2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
6 * ================================================================================
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
18 * ============LICENSE_END=========================================================
21 package org.openecomp.sdc.be.datatypes.category;
23 import org.junit.Assert;
24 import org.junit.Test;
27 public class GroupingDataDefinitionTest {
29 private GroupingDataDefinition createTestSubject() {
30 return new GroupingDataDefinition();
34 public void testCopyConstructor() throws Exception {
35 GroupingDataDefinition testSubject;
38 testSubject = createTestSubject();
39 GroupingDataDefinition groupingDataDefinition = new GroupingDataDefinition(testSubject);
43 public void testGetName() throws Exception {
44 GroupingDataDefinition testSubject;
48 testSubject = createTestSubject();
49 result = testSubject.getName();
54 public void testSetName() throws Exception {
55 GroupingDataDefinition testSubject;
59 testSubject = createTestSubject();
60 testSubject.setName(name);
65 public void testGetNormalizedName() throws Exception {
66 GroupingDataDefinition testSubject;
70 testSubject = createTestSubject();
71 result = testSubject.getNormalizedName();
76 public void testSetNormalizedName() throws Exception {
77 GroupingDataDefinition testSubject;
78 String normalizedName = "";
81 testSubject = createTestSubject();
82 testSubject.setNormalizedName(normalizedName);
87 public void testGetUniqueId() throws Exception {
88 GroupingDataDefinition testSubject;
92 testSubject = createTestSubject();
93 result = testSubject.getUniqueId();
98 public void testSetUniqueId() throws Exception {
99 GroupingDataDefinition testSubject;
100 String uniqueId = "";
103 testSubject = createTestSubject();
104 testSubject.setUniqueId(uniqueId);
109 public void testHashCode() throws Exception {
110 GroupingDataDefinition testSubject;
114 testSubject = createTestSubject();
115 result = testSubject.hashCode();
120 public void testEquals() throws Exception {
121 GroupingDataDefinition testSubject;
126 testSubject = createTestSubject();
128 result = testSubject.equals(obj);
129 Assert.assertEquals(false, result);
130 result = testSubject.equals(testSubject);
131 Assert.assertEquals(true, result);
132 result = testSubject.equals(new GroupingDataDefinition(testSubject));
133 Assert.assertEquals(true, result);
138 public void testToString() throws Exception {
139 GroupingDataDefinition testSubject;
143 testSubject = createTestSubject();
144 result = testSubject.toString();