aboutsummaryrefslogtreecommitdiffstats
path: root/ms/blueprintsprocessor/functions/ansible-awx-executor/src
diff options
context:
space:
mode:
authorJozsef Csongvai <jozsef.csongvai@bell.ca>2021-07-26 12:00:59 -0400
committerJozsef Csongvai <jozsef.csongvai@bell.ca>2021-07-28 15:44:01 -0400
commitdaab14bd058de198c80b71d63e108fd788b7f5ee (patch)
tree252cfdef5b2e1500e5bd152f3f5c52602b6b0deb /ms/blueprintsprocessor/functions/ansible-awx-executor/src
parent82e396d6917519468376d177dd6a2710e84fa23a (diff)
Revert "Renaming Files having BluePrint to have Blueprint"
The renaming in CCSDK-3098 caused breaking changes to the grpc api and compile issues for kotlin scripts. Issue-ID: CCSDK-3385 Change-Id: I0d745cb858371678eabcb2284671c1fd76a1ab6d Signed-off-by: Jozsef Csongvai <jozsef.csongvai@bell.ca>
Diffstat (limited to 'ms/blueprintsprocessor/functions/ansible-awx-executor/src')
-rw-r--r--ms/blueprintsprocessor/functions/ansible-awx-executor/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/ansible/executor/ComponentRemoteAnsibleExecutor.kt4
-rw-r--r--ms/blueprintsprocessor/functions/ansible-awx-executor/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/ansible/executor/ComponentRemoteAnsibleExecutorTest.kt30
2 files changed, 17 insertions, 17 deletions
diff --git a/ms/blueprintsprocessor/functions/ansible-awx-executor/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/ansible/executor/ComponentRemoteAnsibleExecutor.kt b/ms/blueprintsprocessor/functions/ansible-awx-executor/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/ansible/executor/ComponentRemoteAnsibleExecutor.kt
index 2eafcd458..133e4a52b 100644
--- a/ms/blueprintsprocessor/functions/ansible-awx-executor/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/ansible/executor/ComponentRemoteAnsibleExecutor.kt
+++ b/ms/blueprintsprocessor/functions/ansible-awx-executor/src/main/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/ansible/executor/ComponentRemoteAnsibleExecutor.kt
@@ -22,7 +22,7 @@ import com.fasterxml.jackson.databind.ObjectMapper
import com.fasterxml.jackson.databind.node.TextNode
import kotlinx.coroutines.delay
import org.onap.ccsdk.cds.blueprintsprocessor.core.api.data.ExecutionServiceInput
-import org.onap.ccsdk.cds.blueprintsprocessor.rest.service.BlueprintRestLibPropertyService
+import org.onap.ccsdk.cds.blueprintsprocessor.rest.service.BluePrintRestLibPropertyService
import org.onap.ccsdk.cds.blueprintsprocessor.rest.service.BlueprintWebClientService
import org.onap.ccsdk.cds.blueprintsprocessor.services.execution.AbstractComponentFunction
import org.onap.ccsdk.cds.controllerblueprints.core.asJsonNode
@@ -55,7 +55,7 @@ import java.util.NoSuchElementException
@Component("component-remote-ansible-executor")
@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE)
open class ComponentRemoteAnsibleExecutor(
- private val blueprintRestLibPropertyService: BlueprintRestLibPropertyService,
+ private val blueprintRestLibPropertyService: BluePrintRestLibPropertyService,
private val mapper: ObjectMapper
) :
AbstractComponentFunction() {
diff --git a/ms/blueprintsprocessor/functions/ansible-awx-executor/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/ansible/executor/ComponentRemoteAnsibleExecutorTest.kt b/ms/blueprintsprocessor/functions/ansible-awx-executor/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/ansible/executor/ComponentRemoteAnsibleExecutorTest.kt
index 88cf0992f..7be03333f 100644
--- a/ms/blueprintsprocessor/functions/ansible-awx-executor/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/ansible/executor/ComponentRemoteAnsibleExecutorTest.kt
+++ b/ms/blueprintsprocessor/functions/ansible-awx-executor/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/ansible/executor/ComponentRemoteAnsibleExecutorTest.kt
@@ -27,13 +27,13 @@ import org.junit.Test
import org.junit.runner.RunWith
import org.onap.ccsdk.cds.blueprintsprocessor.core.api.data.ExecutionServiceInput
import org.onap.ccsdk.cds.blueprintsprocessor.core.api.data.StepData
-import org.onap.ccsdk.cds.blueprintsprocessor.rest.service.BlueprintRestLibPropertyService
+import org.onap.ccsdk.cds.blueprintsprocessor.rest.service.BluePrintRestLibPropertyService
import org.onap.ccsdk.cds.blueprintsprocessor.rest.service.BlueprintWebClientService
import org.onap.ccsdk.cds.blueprintsprocessor.rest.service.BlueprintWebClientService.WebClientResponse
-import org.onap.ccsdk.cds.controllerblueprints.core.BlueprintConstants
+import org.onap.ccsdk.cds.controllerblueprints.core.BluePrintConstants
import org.onap.ccsdk.cds.controllerblueprints.core.putJsonElement
-import org.onap.ccsdk.cds.controllerblueprints.core.service.BlueprintRuntimeService
-import org.onap.ccsdk.cds.controllerblueprints.core.utils.BlueprintMetadataUtils
+import org.onap.ccsdk.cds.controllerblueprints.core.service.BluePrintRuntimeService
+import org.onap.ccsdk.cds.controllerblueprints.core.utils.BluePrintMetadataUtils
import org.onap.ccsdk.cds.controllerblueprints.core.utils.JacksonUtils
import org.springframework.test.context.TestPropertySource
import org.springframework.test.context.junit4.SpringRunner
@@ -94,7 +94,7 @@ class ComponentRemoteAnsibleExecutorTest {
)
} returns WebClientResponse(200, getReport())
val selector = mapper.readTree(endpointSelector)
- val bluePrintRestLibPropertyService = mockk<BlueprintRestLibPropertyService>()
+ val bluePrintRestLibPropertyService = mockk<BluePrintRestLibPropertyService>()
every { bluePrintRestLibPropertyService.blueprintWebClientService(selector) } returns webClientService
val awxRemoteExecutor = ComponentRemoteAnsibleExecutor(bluePrintRestLibPropertyService, mapper)
awxRemoteExecutor.checkDelay = 1
@@ -112,7 +112,7 @@ class ComponentRemoteAnsibleExecutorTest {
}
// then
- assertTrue(bluePrintRuntimeService.getBlueprintError().allErrors().isEmpty())
+ assertTrue(bluePrintRuntimeService.getBluePrintError().allErrors().isEmpty())
}
@Test
@@ -128,7 +128,7 @@ class ComponentRemoteAnsibleExecutorTest {
webClientService.exchangeResource("GET", "/api/v2/inventories/?name=Demo+Inventory", "")
} returns WebClientResponse(404, "")
val selector = mapper.readTree(endpointSelector)
- val bluePrintRestLibPropertyService = mockk<BlueprintRestLibPropertyService>()
+ val bluePrintRestLibPropertyService = mockk<BluePrintRestLibPropertyService>()
every { bluePrintRestLibPropertyService.blueprintWebClientService(selector) } returns webClientService
val awxRemoteExecutor = ComponentRemoteAnsibleExecutor(bluePrintRestLibPropertyService, mapper)
awxRemoteExecutor.checkDelay = 1
@@ -146,7 +146,7 @@ class ComponentRemoteAnsibleExecutorTest {
}
// then
- val errors = bluePrintRuntimeService.getBlueprintError().allErrors()
+ val errors = bluePrintRuntimeService.getBluePrintError().allErrors()
assertEquals(1, errors.size)
}
@@ -169,7 +169,7 @@ class ComponentRemoteAnsibleExecutorTest {
)
} returns WebClientResponse(500, "")
val selector = mapper.readTree(endpointSelector)
- val bluePrintRestLibPropertyService = mockk<BlueprintRestLibPropertyService>()
+ val bluePrintRestLibPropertyService = mockk<BluePrintRestLibPropertyService>()
every { bluePrintRestLibPropertyService.blueprintWebClientService(selector) } returns webClientService
val awxRemoteExecutor = ComponentRemoteAnsibleExecutor(bluePrintRestLibPropertyService, mapper)
awxRemoteExecutor.checkDelay = 1
@@ -187,15 +187,15 @@ class ComponentRemoteAnsibleExecutorTest {
}
// then
- val errors = bluePrintRuntimeService.getBlueprintError().allErrors()
+ val errors = bluePrintRuntimeService.getBluePrintError().allErrors()
assertEquals(1, errors.size)
}
private fun createBlueprintRuntimeService(
awxRemoteExecutor: ComponentRemoteAnsibleExecutor,
executionServiceInput: ExecutionServiceInput
- ): BlueprintRuntimeService<MutableMap<String, JsonNode>> {
- val bluePrintRuntimeService = BlueprintMetadataUtils.bluePrintRuntime(
+ ): BluePrintRuntimeService<MutableMap<String, JsonNode>> {
+ val bluePrintRuntimeService = BluePrintMetadataUtils.bluePrintRuntime(
"123456-1000",
"./../../../../components/model-catalog/blueprint-model/test-blueprint/remote_ansible"
)
@@ -208,9 +208,9 @@ class ComponentRemoteAnsibleExecutorTest {
bluePrintRuntimeService.assignWorkflowInputs(workflowName, input)
val stepMetaData: MutableMap<String, JsonNode> = hashMapOf()
- stepMetaData.putJsonElement(BlueprintConstants.PROPERTY_CURRENT_NODE_TEMPLATE, "execute-remote-ansible")
- stepMetaData.putJsonElement(BlueprintConstants.PROPERTY_CURRENT_INTERFACE, "ComponentRemoteAnsibleExecutor")
- stepMetaData.putJsonElement(BlueprintConstants.PROPERTY_CURRENT_OPERATION, "process")
+ stepMetaData.putJsonElement(BluePrintConstants.PROPERTY_CURRENT_NODE_TEMPLATE, "execute-remote-ansible")
+ stepMetaData.putJsonElement(BluePrintConstants.PROPERTY_CURRENT_INTERFACE, "ComponentRemoteAnsibleExecutor")
+ stepMetaData.putJsonElement(BluePrintConstants.PROPERTY_CURRENT_OPERATION, "process")
val stepInputData = StepData().apply {
name = "execute-remote-ansible"