aboutsummaryrefslogtreecommitdiffstats
path: root/ms/blueprintsprocessor/application/src
diff options
context:
space:
mode:
authorgummar <raj.gumma@est.tech>2019-11-06 11:48:57 +0000
committergummar <raj.gumma@est.tech>2019-11-22 18:14:04 +0000
commit73a34e905c6abdad567b7063c6e9c3aaa1e42f07 (patch)
tree782455409170a0d09514f31b2ccaa7de4725ce7c /ms/blueprintsprocessor/application/src
parent4dfd7d6f90445fb0a52ccff0a683c8240e4ee9b1 (diff)
CCSDK-1864 : PNF Use Case Move from Jython to Kotlin using CDS Framework
Change-Id: I58eb134a07345d25be6d64dc614f25fc73ecf554 Signed-off-by: gummar <raj.gumma@est.tech> Issue-ID: CCSDK-1864
Diffstat (limited to 'ms/blueprintsprocessor/application/src')
-rw-r--r--ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/uat/UatExecutor.kt4
-rw-r--r--ms/blueprintsprocessor/application/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/uat/BlueprintsAcceptanceTest.kt11
2 files changed, 11 insertions, 4 deletions
diff --git a/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/uat/UatExecutor.kt b/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/uat/UatExecutor.kt
index 6678075bd..4e97460d3 100644
--- a/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/uat/UatExecutor.kt
+++ b/ms/blueprintsprocessor/application/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/uat/UatExecutor.kt
@@ -304,6 +304,10 @@ class UatExecutor(
return realAnswer
}
+ override suspend fun <T> retry(times: Int, initialDelay: Long, delay: Long, block: suspend (Int) -> T): T {
+ return super.retry(times, initialDelay, delay, block)
+ }
+
fun asServiceDefinition() =
ServiceDefinition(selector, expectations)
diff --git a/ms/blueprintsprocessor/application/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/uat/BlueprintsAcceptanceTest.kt b/ms/blueprintsprocessor/application/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/uat/BlueprintsAcceptanceTest.kt
index 4fed0ce67..fa550d1d0 100644
--- a/ms/blueprintsprocessor/application/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/uat/BlueprintsAcceptanceTest.kt
+++ b/ms/blueprintsprocessor/application/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/uat/BlueprintsAcceptanceTest.kt
@@ -19,6 +19,7 @@
*/
package org.onap.ccsdk.cds.blueprintsprocessor.uat
+import kotlinx.coroutines.runBlocking
import org.junit.ClassRule
import org.junit.Rule
import org.junit.runner.RunWith
@@ -38,7 +39,7 @@ import kotlin.test.Test
// See more on https://docs.spring.io/autorepo/docs/spring-framework/current/spring-framework-reference/testing.html#testcontext-junit4-rules
@RunWith(Parameterized::class)
class BlueprintsAcceptanceTest(@Suppress("unused") private val blueprintName: String, // readable test description
- private val rootFs: FileSystem): BaseUatTest() {
+ private val rootFs: FileSystem) : BaseUatTest() {
companion object {
@@ -84,8 +85,10 @@ class BlueprintsAcceptanceTest(@Suppress("unused") private val blueprintName: St
@Test
fun runUat() {
- val uatSpec = rootFs.getPath(UAT_SPECIFICATION_FILE).toFile().readText()
- val cbaBytes = compressToBytes(rootFs.getPath("/"))
- uatExecutor.execute(uatSpec, cbaBytes)
+ runBlocking {
+ val uatSpec = rootFs.getPath(UAT_SPECIFICATION_FILE).toFile().readText()
+ val cbaBytes = compressToBytes(rootFs.getPath("/"))
+ uatExecutor.execute(uatSpec, cbaBytes)
+ }
}
} \ No newline at end of file