summaryrefslogtreecommitdiffstats
path: root/common-be/src/main/java
diff options
context:
space:
mode:
authorxuegao <xue.gao@intl.att.com>2021-03-11 17:22:46 +0100
committerVasyl Razinkov <vasyl.razinkov@est.tech>2021-03-12 11:51:04 +0000
commitf54b124ccfcf596e19d19ba2d24fd2702cd73c8d (patch)
treeed47a30a4fa8e56d12339af900640e1afd853dd6 /common-be/src/main/java
parent74d32db7741c0ab183296acdf6c79b345b39b4ca (diff)
Adding unit tests
Adding unit tests to improve test coverage. Issue-ID: SDC-3428 Signed-off-by: xuegao <xue.gao@intl.att.com> Change-Id: I57da2ff92839cb78985e5f3d3c13dc575c1b6c17
Diffstat (limited to 'common-be/src/main/java')
-rw-r--r--common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/AnnotationTypeDataDefinition.java84
-rw-r--r--common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/MapAttributesDataDefinition.java22
2 files changed, 17 insertions, 89 deletions
diff --git a/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/AnnotationTypeDataDefinition.java b/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/AnnotationTypeDataDefinition.java
index 38e52583c4..8eba3125e3 100644
--- a/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/AnnotationTypeDataDefinition.java
+++ b/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/AnnotationTypeDataDefinition.java
@@ -20,23 +20,27 @@
package org.openecomp.sdc.be.datatypes.elements;
+import lombok.Getter;
+import lombok.NoArgsConstructor;
+import lombok.Setter;
+import lombok.ToString;
import org.openecomp.sdc.be.datatypes.tosca.ToscaDataDefinition;
+@Getter
+@Setter
+@NoArgsConstructor
+@ToString
public class AnnotationTypeDataDefinition extends ToscaDataDefinition {
protected String uniqueId;
protected String type;
+ protected String version;
+ protected boolean highestVersion;
protected String description;
protected Long creationTime;
protected Long modificationTime;
- protected String version;
- protected boolean highestVersion;
-
- public AnnotationTypeDataDefinition() {
- }
-
public AnnotationTypeDataDefinition(AnnotationTypeDataDefinition other) {
uniqueId = other.uniqueId;
type = other.type;
@@ -46,72 +50,4 @@ public class AnnotationTypeDataDefinition extends ToscaDataDefinition {
modificationTime = other.modificationTime;
highestVersion = other.highestVersion;
}
-
- public String getUniqueId() {
- return uniqueId;
- }
-
- public void setUniqueId(String uniqueId) {
- this.uniqueId = uniqueId;
- }
-
- @Override
- public String getType() {
- return type;
- }
-
- public void setType(String type) {
- this.type = type;
- }
-
- public String getDescription() {
- return description;
- }
-
- public void setDescription(String description) {
- this.description = description;
- }
-
- public Long getCreationTime() {
- return creationTime;
- }
-
- public void setCreationTime(Long creationTime) {
- this.creationTime = creationTime;
- }
-
- public Long getModificationTime() {
- return modificationTime;
- }
-
- public void setModificationTime(Long modificationTime) {
- this.modificationTime = modificationTime;
- }
-
- @Override
- public String getVersion() {
- return version;
- }
-
- public void setVersion(String version) {
- this.version = version;
- }
-
- public boolean isHighestVersion() {
- return highestVersion;
- }
-
- public void setHighestVersion(boolean highestVersion) {
- this.highestVersion = highestVersion;
- }
-
- @Override
- public String toString() {
- return getClass().getName() + ": [uniqueId=" + uniqueId + ", type=" + getType()
- + ", version=" + version + ", highestVersion=" + highestVersion
- + ", description=" + description
- + ", creationTime=" + creationTime + ", modificationTime=" + modificationTime + "]";
- }
-
-
}
diff --git a/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/MapAttributesDataDefinition.java b/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/MapAttributesDataDefinition.java
index 31c791681c..af82508813 100644
--- a/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/MapAttributesDataDefinition.java
+++ b/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/MapAttributesDataDefinition.java
@@ -23,9 +23,16 @@ package org.openecomp.sdc.be.datatypes.elements;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
+import lombok.Getter;
+import lombok.NoArgsConstructor;
+import lombok.Setter;
+
import java.util.HashMap;
import java.util.Map;
+@Getter
+@Setter
+@NoArgsConstructor
public class MapAttributesDataDefinition extends MapDataDefinition<AttributeDataDefinition> {
private String parentName;
@@ -49,11 +56,6 @@ public class MapAttributesDataDefinition extends MapDataDefinition<AttributeData
this.mapToscaDataDefinition = toBeDeepCopiedMapPropertiesDataDefinition.mapToscaDataDefinition == null ? null : new HashMap(toBeDeepCopiedMapPropertiesDataDefinition.mapToscaDataDefinition);
}
- public MapAttributesDataDefinition() {
- super();
-
- }
-
@JsonValue
@Override
public Map<String, AttributeDataDefinition> getMapToscaDataDefinition() {
@@ -64,14 +66,4 @@ public class MapAttributesDataDefinition extends MapDataDefinition<AttributeData
public void setMapToscaDataDefinition(Map<String, AttributeDataDefinition> mapToscaDataDefinition) {
this.mapToscaDataDefinition = mapToscaDataDefinition;
}
-
- public String getParentName() {
- return parentName;
- }
-
- public void setParentName(String parentName) {
- this.parentName = parentName;
- }
-
-
}