summaryrefslogtreecommitdiffstats
path: root/ms/blueprintsprocessor/functions/resource-resolution/src
diff options
context:
space:
mode:
authorDan Timoney <dtimoney@att.com>2019-07-31 18:10:44 +0000
committerGerrit Code Review <gerrit@onap.org>2019-07-31 18:10:44 +0000
commitd3e573f5d0f53c8209a8c2e5cf4725abf173eb69 (patch)
tree2f32374f95f412978e8cc2410a465474fa34951f /ms/blueprintsprocessor/functions/resource-resolution/src
parenta4352a3d8742c9befee84bea9f4d8038fdaa4e03 (diff)
parent82753f0646ae2181baf247f51d2909058dcc3707 (diff)
Merge "Fix conflicting catalog service instance names."
Diffstat (limited to 'ms/blueprintsprocessor/functions/resource-resolution/src')
-rw-r--r--ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/mock/MockDatabaseConfiguration.kt11
1 files changed, 8 insertions, 3 deletions
diff --git a/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/mock/MockDatabaseConfiguration.kt b/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/mock/MockDatabaseConfiguration.kt
index 22e043b11..7644df37a 100644
--- a/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/mock/MockDatabaseConfiguration.kt
+++ b/ms/blueprintsprocessor/functions/resource-resolution/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/resource/resolution/mock/MockDatabaseConfiguration.kt
@@ -15,9 +15,11 @@
*/
package org.onap.ccsdk.cds.blueprintsprocessor.functions.resource.resolution.mock
+import io.mockk.every
import io.mockk.mockk
import org.onap.ccsdk.cds.blueprintsprocessor.db.BluePrintDBLibGenericService
import org.onap.ccsdk.cds.controllerblueprints.core.interfaces.BluePrintValidatorService
+import org.onap.ccsdk.cds.controllerblueprints.core.service.BluePrintRuntimeService
import org.springframework.context.annotation.Bean
import org.springframework.context.annotation.Configuration
@@ -33,9 +35,12 @@ open class MockDatabaseConfiguration {
@Configuration
open class MockBlueprintProcessorCatalogServiceImpl {
- @Bean(name = ["blueprintProcessorCatalogServiceImpl"])
- open fun createBlueprintProcessorCatalogServiceImpl(): BluePrintValidatorService {
- return mockk<BluePrintValidatorService>()
+ @Bean(name = ["bluePrintRuntimeValidatorService"])
+ open fun bluePrintRuntimeValidatorService(): BluePrintValidatorService {
+ val bluePrintValidatorService = mockk<BluePrintValidatorService>()
+ every { bluePrintValidatorService.validateBluePrints(any<String>()) } returns true
+ every { bluePrintValidatorService.validateBluePrints(any<BluePrintRuntimeService<*>>()) } returns true
+ return bluePrintValidatorService
}