diff options
author | Steve Smokowski <ss835w@att.com> | 2019-06-07 17:38:37 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2019-06-07 17:38:37 +0000 |
commit | e840e62a5b19755134fc036ab0e3bcbaa06b74c1 (patch) | |
tree | 565feba8ea1ddb0cc3fcb7e2b5f77f30ca2e659b | |
parent | 045294cc45d32bcf6086e2456488e7bedb897e72 (diff) | |
parent | f426e615e3b6f67424a12aff779a56442968707f (diff) |
Merge "change the update line to update the latest stack"
-rw-r--r-- | adapters/mso-adapter-utils/src/main/java/org/onap/so/openstack/utils/MsoHeatUtils.java | 2 | ||||
-rw-r--r-- | adapters/mso-adapter-utils/src/test/java/org/onap/so/openstack/utils/MsoHeatUtilsTest.java | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/adapters/mso-adapter-utils/src/main/java/org/onap/so/openstack/utils/MsoHeatUtils.java b/adapters/mso-adapter-utils/src/main/java/org/onap/so/openstack/utils/MsoHeatUtils.java index bf6374bc2f..7778e53ee3 100644 --- a/adapters/mso-adapter-utils/src/main/java/org/onap/so/openstack/utils/MsoHeatUtils.java +++ b/adapters/mso-adapter-utils/src/main/java/org/onap/so/openstack/utils/MsoHeatUtils.java @@ -326,7 +326,7 @@ public class MsoHeatUtils extends MsoCommonUtils implements VduPlugin { Stack latestStack = null; while (true) { latestStack = queryHeatStack(heatClient, stack.getStackName() + "/" + stack.getId()); - statusHandler.updateStackStatus(stack); + statusHandler.updateStackStatus(latestStack); logger.debug("Polling: {} ({})", latestStack.getStackStatus(), latestStack.getStackName()); if (stackStatus.equals(latestStack.getStackStatus())) { if (numberOfPollingAttempts <= 0) { diff --git a/adapters/mso-adapter-utils/src/test/java/org/onap/so/openstack/utils/MsoHeatUtilsTest.java b/adapters/mso-adapter-utils/src/test/java/org/onap/so/openstack/utils/MsoHeatUtilsTest.java index 5a2515a81e..9f577d8679 100644 --- a/adapters/mso-adapter-utils/src/test/java/org/onap/so/openstack/utils/MsoHeatUtilsTest.java +++ b/adapters/mso-adapter-utils/src/test/java/org/onap/so/openstack/utils/MsoHeatUtilsTest.java @@ -126,7 +126,7 @@ public class MsoHeatUtilsTest extends MsoHeatUtils { doReturn(latestStack).when(heatUtils).queryHeatStack(isA(Heat.class), eq("stackName/id")); doReturn(heatClient).when(heatUtils).getHeatClient(cloudSiteId, tenantId); Stack actual = heatUtils.pollStackForStatus(1, stack, "CREATE_IN_PROGRESS", cloudSiteId, tenantId); - Mockito.verify(stackStatusHandler, times(1)).updateStackStatus(stack); + Mockito.verify(stackStatusHandler, times(1)).updateStackStatus(latestStack); Mockito.verify(heatUtils, times(1)).queryHeatStack(isA(Heat.class), eq("stackName/id")); assertEquals(true, actual != null); } |