summaryrefslogtreecommitdiffstats
path: root/ms/controllerblueprints/modules/blueprint-core
diff options
context:
space:
mode:
authorMuthuramalingam, Brinda Santh <brindasanth@in.ibm.com>2019-03-26 23:08:06 -0400
committerMuthuramalingam, Brinda Santh <brindasanth@in.ibm.com>2019-03-27 13:25:48 -0400
commit13a13e62b4c01db42c7488f9b36d4667ad3e2321 (patch)
treee6ddfd88dcadb1d2e65536a40e0298dfda2d6f5e /ms/controllerblueprints/modules/blueprint-core
parentfe521ab3fc62a2dc66bda6710885b8160daf21c1 (diff)
Add Restconf Kotlin script sample
Change-Id: Ia6196c7e45b1f3d8a3598f858f0d8380a3463ae9 Issue-ID: CCSDK-1080 Signed-off-by: Muthuramalingam, Brinda Santh <brindasanth@in.ibm.com>
Diffstat (limited to 'ms/controllerblueprints/modules/blueprint-core')
-rw-r--r--ms/controllerblueprints/modules/blueprint-core/src/test/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/FileExtensionFunctionTest.kt34
1 files changed, 34 insertions, 0 deletions
diff --git a/ms/controllerblueprints/modules/blueprint-core/src/test/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/FileExtensionFunctionTest.kt b/ms/controllerblueprints/modules/blueprint-core/src/test/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/FileExtensionFunctionTest.kt
new file mode 100644
index 000000000..9a0da6905
--- /dev/null
+++ b/ms/controllerblueprints/modules/blueprint-core/src/test/kotlin/org/onap/ccsdk/cds/controllerblueprints/core/FileExtensionFunctionTest.kt
@@ -0,0 +1,34 @@
+/*
+ * 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.
+ */
+
+package org.onap.ccsdk.cds.controllerblueprints.core
+
+import org.junit.Test
+import kotlin.test.assertTrue
+
+class FileExtensionFunctionTest {
+ val blueprintBasePath = "./../../../../components/model-catalog/blueprint-model/test-blueprint/baseconfiguration"
+
+ @Test
+ fun testCompress() {
+ val blueprintFile = normalizedFile(blueprintBasePath)
+ val targetZip = normalizedFile("target", "compress.zip")
+ targetZip.deleteRecursively()
+ blueprintFile.compress(targetZip)
+ assertTrue(blueprintFile.exists(), "failed to create compressed file(${targetZip.absolutePath} ")
+ }
+
+} \ No newline at end of file