mirror of
				https://github.com/optim-enterprises-bv/kubernetes.git
				synced 2025-11-03 19:58:17 +00:00 
			
		
		
		
	add debugging to the client watch test
This commit is contained in:
		@@ -100,12 +100,19 @@ func observeCreation(w watch.Interface) {
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
func observeObjectDeletion(w watch.Interface) (obj runtime.Object) {
 | 
					func observeObjectDeletion(w watch.Interface) (obj runtime.Object) {
 | 
				
			||||||
 | 
						// output to give us a duration to failure.  Maybe we aren't getting the
 | 
				
			||||||
 | 
						// full timeout for some reason.  My guess would be watch failure
 | 
				
			||||||
 | 
						framework.Logf("Starting to observe pod deletion")
 | 
				
			||||||
	deleted := false
 | 
						deleted := false
 | 
				
			||||||
	timeout := false
 | 
						timeout := false
 | 
				
			||||||
	timer := time.After(60 * time.Second)
 | 
						timer := time.After(60 * time.Second)
 | 
				
			||||||
	for !deleted && !timeout {
 | 
						for !deleted && !timeout {
 | 
				
			||||||
		select {
 | 
							select {
 | 
				
			||||||
		case event, _ := <-w.ResultChan():
 | 
							case event, normal := <-w.ResultChan():
 | 
				
			||||||
 | 
								if !normal {
 | 
				
			||||||
 | 
									framework.Failf("The channel was closed unexpectedly")
 | 
				
			||||||
 | 
									return
 | 
				
			||||||
 | 
								}
 | 
				
			||||||
			if event.Type == watch.Deleted {
 | 
								if event.Type == watch.Deleted {
 | 
				
			||||||
				obj = event.Object
 | 
									obj = event.Object
 | 
				
			||||||
				deleted = true
 | 
									deleted = true
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user