diff options
Diffstat (limited to 'ms/controllerblueprints/modules/service')
2 files changed, 16 insertions, 1 deletions
diff --git a/ms/controllerblueprints/modules/service/pom.xml b/ms/controllerblueprints/modules/service/pom.xml index 73fe0739b..7ca7e0db0 100644 --- a/ms/controllerblueprints/modules/service/pom.xml +++ b/ms/controllerblueprints/modules/service/pom.xml @@ -21,7 +21,7 @@ <parent> <groupId>org.onap.ccsdk.apps.controllerblueprints</groupId> <artifactId>modules</artifactId> - <version>0.4.1-SNAPSHOT</version> + <version>0.4.2-SNAPSHOT</version> </parent> <artifactId>service</artifactId> <name>Controller Blueprints Service</name> diff --git a/ms/controllerblueprints/modules/service/src/test/kotlin/org/onap/ccsdk/apps/controllerblueprints/service/enhancer/BluePrintEnhancerServiceImplTest.kt b/ms/controllerblueprints/modules/service/src/test/kotlin/org/onap/ccsdk/apps/controllerblueprints/service/enhancer/BluePrintEnhancerServiceImplTest.kt index 48183f4cb..e0ecf0397 100644 --- a/ms/controllerblueprints/modules/service/src/test/kotlin/org/onap/ccsdk/apps/controllerblueprints/service/enhancer/BluePrintEnhancerServiceImplTest.kt +++ b/ms/controllerblueprints/modules/service/src/test/kotlin/org/onap/ccsdk/apps/controllerblueprints/service/enhancer/BluePrintEnhancerServiceImplTest.kt @@ -31,6 +31,7 @@ import org.springframework.beans.factory.annotation.Autowired import org.springframework.test.context.ContextConfiguration import org.springframework.test.context.TestPropertySource import org.springframework.test.context.junit4.SpringRunner +import java.io.File import java.nio.file.Paths @RunWith(SpringRunner::class) @@ -81,11 +82,20 @@ class BluePrintEnhancerServiceImplTest { testComponentInvokeEnhancementAndValidation(basePath, "golden-enhance") } + @Test + @Throws(Exception::class) + fun testCapabilityRestconfEnhancementAndValidation() { + val basePath = "./../../../../components/model-catalog/blueprint-model/test-blueprint/capability_restconf" + testComponentInvokeEnhancementAndValidation(basePath, "capability_restconf-enhance") + + } private fun testComponentInvokeEnhancementAndValidation(basePath: String, targetDirName: String) { val targetPath = Paths.get("target", targetDirName).toUri().path + deleteTargetDirectory(targetPath) + val bluePrintContext = bluePrintEnhancerService.enhance(basePath, targetPath) Assert.assertNotNull("failed to get blueprintContext ", bluePrintContext) @@ -94,4 +104,9 @@ class BluePrintEnhancerServiceImplTest { Assert.assertTrue("blueprint($basePath) validation failed ", valid) } + private fun deleteTargetDirectory(targetPath: String) { + val targetDirectory = File(targetPath) + targetDirectory.deleteRecursively() + } + }
\ No newline at end of file |