Merge pull request #27536 from mwielgus/log-np-del

Automatic merge from submit-queue

Log node-pool deletion in cluster autoscaler tests

cc: @piosz @jszczepkowski
pull/6/head
k8s-merge-robot 2016-06-16 10:55:21 -07:00 committed by GitHub
commit 3ba5816e46
1 changed files with 11 additions and 4 deletions

View File

@ -206,10 +206,17 @@ var _ = framework.KubeDescribe("Cluster size autoscaling [Slow]", func() {
"--project="+framework.TestContext.CloudConfig.ProjectID,
"--zone="+framework.TestContext.CloudConfig.Zone,
"--cluster="+framework.TestContext.CloudConfig.Cluster).CombinedOutput()
defer exec.Command("gcloud", "alpha", "container", "node-pools", "delete", extraPoolName, "--quiet",
"--project="+framework.TestContext.CloudConfig.ProjectID,
"--zone="+framework.TestContext.CloudConfig.Zone,
"--cluster="+framework.TestContext.CloudConfig.Cluster).CombinedOutput()
defer func() {
glog.Infof("Deleting node pool %s", extraPoolName)
output, err := exec.Command("gcloud", "alpha", "container", "node-pools", "delete", extraPoolName, "--quiet",
"--project="+framework.TestContext.CloudConfig.ProjectID,
"--zone="+framework.TestContext.CloudConfig.Zone,
"--cluster="+framework.TestContext.CloudConfig.Cluster).CombinedOutput()
if err != nil {
glog.Infof("Error: %v", err)
}
glog.Infof("Node-pool deletion output: %s", output)
}()
framework.ExpectNoError(err)
glog.Infof("Creating node-pool: %s", output)
framework.ExpectNoError(framework.WaitForClusterSize(c, nodeCount+1, resizeTimeout))