HPA e2e tests: fixed problem w/blocking channel.

HPA e2e tests: fixed problem w/blocking channel. Resolves #38298.
This commit is contained in:
Jerzy Szczepkowski 2016-12-08 10:59:58 +01:00
parent 6b9a944285
commit e94d2fdc4e

View File

@ -299,9 +299,9 @@ func (rc *ResourceConsumer) EnsureDesiredReplicas(desiredReplicas int, timeout t
func (rc *ResourceConsumer) CleanUp() {
By(fmt.Sprintf("Removing consuming RC %s", rc.name))
rc.stopCPU <- 0
rc.stopMem <- 0
rc.stopCustomMetric <- 0
close(rc.stopCPU)
close(rc.stopMem)
close(rc.stopCustomMetric)
// Wait some time to ensure all child goroutines are finished.
time.Sleep(10 * time.Second)
framework.ExpectNoError(framework.DeleteRCAndPods(rc.framework.ClientSet, rc.framework.InternalClientset, rc.framework.Namespace.Name, rc.name))