File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -113,16 +113,15 @@ def test_deploy_vm_from_iso(self):
113113 self .cleanup .append (self .iso )
114114
115115 self .debug ("ISO created with ID: %s" % self .iso .id )
116-
117116 list_iso_response = Iso .list (
118117 self .apiclient ,
119118 id = self .iso .id
120119 )
121- self . assertEqual (
122- isinstance ( list_iso_response , list ),
123- True ,
124- "Check list response returns a valid list"
125- )
120+ while not isinstance ( list_iso_response , list ):
121+ list_iso_response = Iso . list (
122+ self . apiclient ,
123+ id = self . iso . id
124+ )
126125
127126 try :
128127 # Download the ISO
@@ -163,11 +162,10 @@ def test_deploy_vm_from_iso(self):
163162 VirtualMachine .RUNNING
164163 )
165164
166- self .assertEqual (
167- vm_state ,
168- VirtualMachine .RUNNING ,
169- "Check virtual machine is in running state"
170- )
165+ response = self .virtual_machine .getState (
166+ self .apiclient ,
167+ VirtualMachine .RUNNING )
168+ self .assertEqual (response [0 ], PASS , response [1 ])
171169
172170 self .assertEqual (
173171 vm_response .isoid ,
You can’t perform that action at this time.
0 commit comments