diff options
author | Sudarshan Kumar <sudars19@in.ibm.com> | 2019-02-21 22:51:01 +0530 |
---|---|---|
committer | Takamune Cho <takamune.cho@att.com> | 2019-02-28 22:05:33 +0000 |
commit | 43a3aa0b19516eb491f5fd4e9e9dccafb78d4640 (patch) | |
tree | 9e87810368e7687849751d58b4be751c70cdd8db /appc-dispatcher | |
parent | 15e930973a9de66dda48afa639b31188061f9bd1 (diff) |
Added Junit Class For LicenseModelBuilder.java
Added Junit Class For LicenseModelBuilder.java
Issue-ID: APPC-1372
Change-Id: I9acb703ccec2775c5c64e0be3a14ea93eb85b868
Signed-off-by: Sudarshan Kumar <sudars19@in.ibm.com>
Diffstat (limited to 'appc-dispatcher')
-rw-r--r-- | appc-dispatcher/appc-license-manager/appc-license-manager-api/src/test/java/org/onap/appc/licmgr/LicenseModelBuilderTest.java | 63 |
1 files changed, 63 insertions, 0 deletions
diff --git a/appc-dispatcher/appc-license-manager/appc-license-manager-api/src/test/java/org/onap/appc/licmgr/LicenseModelBuilderTest.java b/appc-dispatcher/appc-license-manager/appc-license-manager-api/src/test/java/org/onap/appc/licmgr/LicenseModelBuilderTest.java new file mode 100644 index 000000000..bf2fccdfa --- /dev/null +++ b/appc-dispatcher/appc-license-manager/appc-license-manager-api/src/test/java/org/onap/appc/licmgr/LicenseModelBuilderTest.java @@ -0,0 +1,63 @@ +/* + * ============LICENSE_START======================================================= + * ONAP : APPC + * ================================================================================ + * Copyright 2019 IBM + *================================================================================= + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ +package org.onap.appc.licmgr; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNotNull; +import static org.junit.Assert.assertSame; + +import org.junit.Before; +import org.junit.Test; +import org.onap.appc.licmgr.objects.LicenseModelBuilder; + +public class LicenseModelBuilderTest { + + LicenseModelBuilder licenseModelBuilder; + + @Before + public void setUp() { + licenseModelBuilder = new LicenseModelBuilder(); + } + + @Test + public void testSetEntitlementPoolUuid() { + String entitlementPoolUuid = "entitlementPoolUuid"; + LicenseModelBuilder licenseModelBuilderObj = licenseModelBuilder.setEntitlementPoolUuid(entitlementPoolUuid); + assertSame(licenseModelBuilder, licenseModelBuilderObj); + } + + @Test + public void testsetLicenseKeyGroupUuid() { + String licenseKeyGroupUuid = "licenseKeyGroupUuid"; + LicenseModelBuilder licenseModelBuilderObj = licenseModelBuilder.setLicenseKeyGroupUuid(licenseKeyGroupUuid); + assertSame(licenseModelBuilder, licenseModelBuilderObj); + } + + @Test + public void testIsReady() { + assertEquals(false, licenseModelBuilder.isReady()); + } + + @Test + public void testBuild() { + assertNotNull(licenseModelBuilder.build()); + } + +} |