summaryrefslogtreecommitdiffstats
path: root/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/test/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntityTest.java
diff options
context:
space:
mode:
authorBen David, Elad (eb7504) <eb7504@intl.att.com>2020-03-17 18:12:17 +0200
committerOfir Sonsino <ofir.sonsino@intl.att.com>2020-03-23 08:06:19 +0000
commitec7da6aea30a1b73d1e0f5f75d2b6119ed8fa251 (patch)
treede325ed98badf0aa456b52d3f10257dec26a8228 /openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/test/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntityTest.java
parent1a64c83fc436e17f93e468f7d46ff9f5fcb081ce (diff)
Entitlement Pool - Support Type Field
Change-Id: Ibd9996cce04849332bd23dd62e6143386cdd9a70 Issue-ID: SDC-2820 Signed-off-by: Ben David, Elad (eb7504) <eb7504@intl.att.com>
Diffstat (limited to 'openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/test/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntityTest.java')
-rw-r--r--openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/test/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntityTest.java14
1 files changed, 14 insertions, 0 deletions
diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/test/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntityTest.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/test/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntityTest.java
index 7ff6fb78f5..0c28ceef36 100644
--- a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/test/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntityTest.java
+++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/test/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntityTest.java
@@ -21,6 +21,7 @@ import static org.testng.Assert.assertEquals;
import java.util.Collections;
import java.util.HashSet;
import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity;
+import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolType;
import org.openecomp.sdc.vendorlicense.dao.types.OperationalScope;
import org.openecomp.sdcrests.vendorlicense.types.EntitlementPoolRequestDto;
import org.openecomp.sdcrests.vendorlicense.types.MultiChoiceOrOtherDto;
@@ -126,6 +127,19 @@ public class MapEntitlementPoolRequestDtoToEntitlementPoolEntityTest {
assertEquals(target.getManufacturerReferenceNumber(), param);
}
+ @Test
+ public void testType() {
+ EntitlementPoolRequestDto source = new EntitlementPoolRequestDto();
+ EntitlementPoolEntity target = new EntitlementPoolEntity();
+ MapEntitlementPoolRequestDtoToEntitlementPoolEntity mapper = new
+ MapEntitlementPoolRequestDtoToEntitlementPoolEntity();
+ EntitlementPoolType entitlementPoolType = EntitlementPoolType.Universal;
+ source.setType(entitlementPoolType);
+ mapper.doMapping(source, target);
+ assertEquals(target.getType(), entitlementPoolType);
+ }
+
+
enum TestEnum {
Yes
}