Error: timed out waiting for the condition during long helm tests

2/14/2020

How can I force helm to wait for the end of the test suite?

 $ helm test $RELEASE --namespace $NAMESPACE
 NAME: myproject-test
 LAST DEPLOYED: Fri Feb 14 10:43:04 2020
 NAMESPACE: myproject-test-vjuh-init-helm
 STATUS: deployed
 REVISION: 1
 TEST SUITE:     myproject-test-django-test
 Last Started:   Fri Feb 14 10:45:53 2020
 Last Completed: Fri Feb 14 10:50:54 2020
 Phase:          Failed
 NOTES:
 Deployed
 Error: timed out waiting for the condition
 ERROR: Job failed: exit code 1
-- Vincent J
kubernetes-helm

1 Answer

2/14/2020

Add --timeout 30m or longer to your helm command:

helm test $RELEASE --namespace $NAMESPACE --timeout 30m

As stated in the manual helm test --help:

--timeout duration   time to wait for any individual Kubernetes operation (like Jobs for hooks) (default 5m0s)
-- Vincent J
Source: StackOverflow