mirror of
				https://github.com/optim-enterprises-bv/kubernetes.git
				synced 2025-11-04 04:08:16 +00:00 
			
		
		
		
	Merge pull request #79392 from Bowenislandsong/master
adding pre-condition for an e2e scheduler test
This commit is contained in:
		@@ -172,6 +172,10 @@ var _ = framework.KubeDescribe("EquivalenceCache [Serial]", func() {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
	// This test verifies that MatchInterPodAffinity (anti-affinity) is respected as expected.
 | 
						// This test verifies that MatchInterPodAffinity (anti-affinity) is respected as expected.
 | 
				
			||||||
	ginkgo.It("validates pod anti-affinity works properly when new replica pod is scheduled", func() {
 | 
						ginkgo.It("validates pod anti-affinity works properly when new replica pod is scheduled", func() {
 | 
				
			||||||
 | 
							// check if there are at least 2 worker nodes available, else skip this test.
 | 
				
			||||||
 | 
							if len(nodeList.Items) < 2 {
 | 
				
			||||||
 | 
								framework.Skipf("Skipping as the test requires at least two worker nodes, current number of nodes: %d", len(nodeList.Items))
 | 
				
			||||||
 | 
							}
 | 
				
			||||||
		ginkgo.By("Launching two pods on two distinct nodes to get two node names")
 | 
							ginkgo.By("Launching two pods on two distinct nodes to get two node names")
 | 
				
			||||||
		CreateHostPortPods(f, "host-port", 2, true)
 | 
							CreateHostPortPods(f, "host-port", 2, true)
 | 
				
			||||||
		defer framework.DeleteRCAndWaitForGC(f.ClientSet, ns, "host-port")
 | 
							defer framework.DeleteRCAndWaitForGC(f.ClientSet, ns, "host-port")
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user