From aa3f6d9d6d87d265319820eaecb77dabed010a7b Mon Sep 17 00:00:00 2001 From: Jozsef Csongvai Date: Wed, 9 Dec 2020 19:49:48 -0500 Subject: Refactoring to enable on_failure for imperative workflow BlueprintError needs to associate errors with the steps in which they occurred in order for imperative workflow to handle on_failure properly. Made stepName more accessible and corrected places where stepName was assigned to nodeTemplateName. Issue-ID: CCSDK-3219 Change-Id: I7e5805745c63558cff6be533e1b99c32ad06c3db Signed-off-by: Jozsef Csongvai (cherry picked from commit b96b44d6d7ca11dbbc3ad4bd2194df31fba5efb6) --- .../config/snapshots/ComponentConfigSnapshotsExecutorTest.kt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'ms/blueprintsprocessor/functions/config-snapshots') diff --git a/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/ComponentConfigSnapshotsExecutorTest.kt b/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/ComponentConfigSnapshotsExecutorTest.kt index acdbe070f..99de66489 100644 --- a/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/ComponentConfigSnapshotsExecutorTest.kt +++ b/ms/blueprintsprocessor/functions/config-snapshots/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/config/snapshots/ComponentConfigSnapshotsExecutorTest.kt @@ -247,7 +247,7 @@ class ComponentConfigSnapshotsExecutorTest { } // then; we should get error in our output properties - assertTrue(bluePrintRuntimeService.getBlueprintError().errors.size == 1) + assertTrue(bluePrintRuntimeService.getBlueprintError().allErrors().size == 1) assertEquals( ComponentConfigSnapshotsExecutor.OUTPUT_STATUS_ERROR.asJsonPrimitive(), bluePrintRuntimeService.getNodeTemplateAttributeValue( @@ -328,7 +328,7 @@ class ComponentConfigSnapshotsExecutorTest { } // then; we should get success - assertTrue(bluePrintRuntimeService.getBlueprintError().errors.size == 0) + assertTrue(bluePrintRuntimeService.getBlueprintError().allErrors().size == 0) assertEquals( ComponentConfigSnapshotsExecutor.OUTPUT_STATUS_SUCCESS.asJsonPrimitive(), bluePrintRuntimeService.getNodeTemplateAttributeValue( @@ -377,7 +377,7 @@ class ComponentConfigSnapshotsExecutorTest { } // then; we should get success - assertTrue(bluePrintRuntimeService.getBlueprintError().errors.size == 0) + assertTrue(bluePrintRuntimeService.getBlueprintError().allErrors().size == 0) assertEquals( ComponentConfigSnapshotsExecutor.OUTPUT_STATUS_SUCCESS.asJsonPrimitive(), bluePrintRuntimeService.getNodeTemplateAttributeValue( -- cgit 1.2.3-korg