@@ -30,12 +30,16 @@ import (
3030 kc "github.com/deckhouse/virtualization/tests/e2e/kubectl"
3131)
3232
33- func WaitVMNetworkReady (opts kc.WaitOptions ) {
33+ func WaitForVMNetworkReady (opts kc.WaitOptions ) {
3434 GinkgoHelper ()
35- WaitPhaseByLabel (kc .ResourceVM , PhaseRunning , opts )
3635 WaitConditionIsTrueByLabel (kc .ResourceVM , vmcondition .TypeNetworkReady .String (), opts )
3736}
3837
38+ func WaitForVMRunningPhase (opts kc.WaitOptions ) {
39+ GinkgoHelper ()
40+ WaitPhaseByLabel (kc .ResourceVM , PhaseRunning , opts )
41+ }
42+
3943var _ = Describe ("VirtualMachineAdditionalNetworkInterfaces" , SIGMigration (), ginkgoutil .CommonE2ETestDecorators (), func () {
4044 testCaseLabel := map [string ]string {"testcase" : "vm-vpc" }
4145 var ns string
@@ -84,16 +88,16 @@ var _ = Describe("VirtualMachineAdditionalNetworkInterfaces", SIGMigration(), gi
8488
8589 Context ("When virtual machines are applied" , func () {
8690 It ("checks VMs phases" , func () {
87- By ("Virtual machine agents should be ready " )
88- WaitVMAgentReady (kc.WaitOptions {
91+ By ("Virtual machine should be running " )
92+ WaitForVMRunningPhase (kc.WaitOptions {
8993 Labels : testCaseLabel ,
9094 Namespace : ns ,
9195 Timeout : MaxWaitTimeout ,
9296 })
9397 })
9498 It ("checks network availability" , func () {
9599 By ("Network condition should be true" )
96- WaitVMNetworkReady (kc.WaitOptions {
100+ WaitForVMNetworkReady (kc.WaitOptions {
97101 Labels : testCaseLabel ,
98102 Namespace : ns ,
99103 Timeout : MaxWaitTimeout ,
@@ -151,7 +155,7 @@ var _ = Describe("VirtualMachineAdditionalNetworkInterfaces", SIGMigration(), gi
151155
152156 It ("checks network availability after migrations" , func () {
153157 By ("Network condition should be true" )
154- WaitVMNetworkReady (kc.WaitOptions {
158+ WaitForVMNetworkReady (kc.WaitOptions {
155159 Labels : testCaseLabel ,
156160 Namespace : ns ,
157161 Timeout : MaxWaitTimeout ,
0 commit comments