ronazhan commented on a change in pull request #292:
URL: 
https://github.com/apache/incubator-yunikorn-k8shim/pull/292#discussion_r681381919



##########
File path: test/e2e/app/app_test.go
##########
@@ -113,6 +113,16 @@ var _ = ginkgo.Describe("App", func() {
                        
gomega.Ω(appCRD.Spec.TaskGroups[0].Tolerations[0].Effect).To(gomega.Equal(v1.TaintEffectNoSchedule))
                })
 
+               ginkgo.It("Verify the Yunikorn Scheduler healthy", func() {
+                       ginkgo.By("Call the HealthCheck API")
+                       healthCheck, err := yunikorn.GetHealthCheck()
+                       gomega.Ω(err).NotTo(gomega.HaveOccurred())
+                       gomega.Ω(healthCheck.Healthy).To(gomega.BeTrue())
+                       for _, check := range healthCheck.HealthChecks {
+                               gomega.Ω(check.Succeeded).To(gomega.BeTrue())
+                       }
+               })

Review comment:
       Instead of making this a standalone test for each suite, include the 
health check as part of the AfterEach(). Should not be much overhead for just a 
rest call, and this will make it easier to pinpoint after which test Yunikorn 
scheduler entered unhealthy state. 
   
   Each suite can have an AfterEach, and the AfterEach code will run after each 
test in the suite.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to