Merge "Add check for hypervisor state before getting uptime"

This commit is contained in:
Zuul 2018-09-05 15:11:10 +00:00 committed by Gerrit Code Review
commit 293e36c61d

View File

@ -79,7 +79,8 @@ class HypervisorAdminTestJSON(HypervisorAdminTestBase):
for hyper in hypers:
details = (self.client.show_hypervisor(hyper['id'])
['hypervisor'])
if details['hypervisor_type'] != 'ironic':
if (details['hypervisor_type'] != 'ironic' and
details['state'] == 'up'):
hypers_without_ironic.append(hyper)
ironic_only = False