Change e2e Tests Retry to iteration count #351
Labels
carvel-accepted
This issue should be considered for future work and that the triage process has been completed
good first issue
An issue that will be a good candidate for a new contributor
kind/cleanup
engineering focused non-feature work
priority/important-longterm
Important over the long term, but may not be staffed and/or may need multiple releases to complete.
snack
This issue has been identified as lightweight and potentially quick to deliver.
Currently our e2e tests use a time-based retry (see e.g. https://github.com/vmware-tanzu/carvel-kapp-controller/blob/develop/test/e2e/kappcontroller/app_secret_configmap_reconcile_test.go#L98 ) , but time is notoriously slippery, especially in "the cloud" (see also https://gist.github.com/timvisee/fcda9bbdff88d45cc9061606b4b923ca ).
Very likely we can replace the existing retry function with a counter that takes an integer (e.g. 10) instead of a time duration (e.g.
10 * time.seconds
) and still calls Sleep(1) ten times.Ideally after this task none of our e2e tests will rely on comparing a start time with the current time to determine whether they've retried enough, but if there's one or two cases that are thornier i think an incremental improvement will also be greatly appreciated.
The text was updated successfully, but these errors were encountered: