Skip to content

Commit

Permalink
test: increase e2e pod delete timeout tolerance to 5 mins (Azure#662)
Browse files Browse the repository at this point in the history
  • Loading branch information
jackfrancis authored and danmassie committed Mar 9, 2019
1 parent 4af5325 commit 08d0d19
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion test/e2e/kubernetes/pod/pod.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import (
const (
testDir string = "testdirectory"
commandTimeout = 1 * time.Minute
deleteTimeout = 5 * time.Minute
)

// List is a container that holds all pods returned from doing a kubectl get pods
Expand Down Expand Up @@ -574,7 +575,7 @@ func (p *Pod) Delete(retries int) error {
var kubectlError error
for i := 0; i < retries; i++ {
cmd := exec.Command("k", "delete", "po", "-n", p.Metadata.Namespace, p.Metadata.Name)
kubectlOutput, kubectlError = util.RunAndLogCommand(cmd, commandTimeout)
kubectlOutput, kubectlError = util.RunAndLogCommand(cmd, deleteTimeout)
if kubectlError != nil {
log.Printf("Error while trying to delete Pod %s in namespace %s:%s\n", p.Metadata.Namespace, p.Metadata.Name, string(kubectlOutput))
continue
Expand Down

0 comments on commit 08d0d19

Please sign in to comment.