aboutsummaryrefslogtreecommitdiffstats
path: root/adapters/mso-openstack-adapters/src/test/java/org
diff options
context:
space:
mode:
authorBenjamin, Max (mb388a) <mb388a@us.att.com>2019-02-14 19:54:00 -0500
committerBenjamin, Max (mb388a) <mb388a@us.att.com>2019-02-14 19:55:59 -0500
commitf950d102e204be4f23b675997648c370ad2c0c3b (patch)
treebc2adc620f5c82625c7ec6605f45b313344cbf70 /adapters/mso-openstack-adapters/src/test/java/org
parent1d69925fef5c972f045081db9b5e4795d96c6f84 (diff)
fix issue where we attempt audit with no servers
fix issue where we attempt audit with no servers Change-Id: I47f76121c616bf65a5f8be73910adcc0d7088bdb Issue-ID: SO-1513 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
Diffstat (limited to 'adapters/mso-openstack-adapters/src/test/java/org')
-rw-r--r--adapters/mso-openstack-adapters/src/test/java/org/onap/so/adapters/audit/HeatStackAuditTest.java11
1 files changed, 11 insertions, 0 deletions
diff --git a/adapters/mso-openstack-adapters/src/test/java/org/onap/so/adapters/audit/HeatStackAuditTest.java b/adapters/mso-openstack-adapters/src/test/java/org/onap/so/adapters/audit/HeatStackAuditTest.java
index b3cdd467bb..696784110b 100644
--- a/adapters/mso-openstack-adapters/src/test/java/org/onap/so/adapters/audit/HeatStackAuditTest.java
+++ b/adapters/mso-openstack-adapters/src/test/java/org/onap/so/adapters/audit/HeatStackAuditTest.java
@@ -196,6 +196,17 @@ public class HeatStackAuditTest extends HeatStackAudit {
JSONAssert.assertEquals(expectedValue, actualValue, false);
}
+ @Test
+ public void auditHeatStackNoServers_Test() throws Exception{
+
+
+ Resources getResource = objectMapper.readValue(new File("src/test/resources/Service1ResourceGroupResponse.json"), Resources.class);
+ doReturn(getResource).when(msoHeatUtilsMock).queryStackResources(cloudRegion, tenantId, "heatStackName");
+
+ boolean actual = heatStackAudit.auditHeatStack(cloudRegion, "cloudOwner", tenantId, "heatStackName");
+ assertEquals(true, actual);
+ }
+
@Test
public void findInterfaceInformation_Test(){