Repository navigation
test(vpc_endpoint): wait for the sync and give deletes 30s - #409
Conversation
Three tests deleted the CR with the acktest default wait, one check 5 seconds after the delete, and failed when DeleteVpcEndpoints took longer. They now pass 3, 10 like the fixtures in this file. The fixtures returned the CR as soon as it had a status, which can hold only conditions while the create fails (VpcEndpointLimitExceeded), and the tests failed with KeyError: 'vpcEndpointID'. The fixtures now wait for ACK.ResourceSynced=True before the tests read the status. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Hi @gecube. Thanks for your PR. I'm waiting for a aws-controllers-k8s member to verify that this patch is reasonable to test. If it is, they should reply with Regular contributors should join the org to skip this step. Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
/ok-to-test |
|
/LGTM |
Issue #, if available: aws-controllers-k8s/community#3159 Description of changes: 42 calls in 14 e2e test files deleted a CR with the acktest default wait (`wait_periods=1, period_length=5`: one check, 5 seconds after the delete) and then asserted that the CR was gone. A delete that takes a little longer, or waits in the queue behind another delete of the same kind, fails the test although the controller completes it. That is how `TestVpcEndpoint` failed on aws-controllers-k8s/runtime#286 (details in the issue). These calls now pass `3, 10` (up to 30 seconds), as most calls in the suite already do. Only the arguments change. The wait returns as soon as the CR is gone, so a test that passed before still passes; a delete that finishes within 5 seconds now waits for the first check at 10 seconds instead of 5. Not changed: - `test_vpc_endpoint.py`: #409 changes it, together with a fix for its fixtures. - Six calls in `test_security_group.py` that do not check the result and sleep after the delete. Checked with `python3 -m py_compile` on every changed file; the e2e suite itself runs only in CI. By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
The modify fixture waited 100 s for ACK.ResourceSynced=True, but the interface endpoint it creates stays pending for about 5.5 minutes, so test_update_subnets and test_update_security_groups failed in setup. Wait as long as test_update_security_groups already does. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
@gustavodiaz7722 the modify fixture waited only 100 s for the interface endpoint, which stays pending for about 5.5 minutes; 1e1b134 makes it wait as long as test_update_security_groups does. ec2-kind-e2e is green now (110 passed). Could you kindly take another look? |
|
/LGTM |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: gecube, gustavodiaz7722 The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Issue #, if available: aws-controllers-k8s/community#3159
Description of changes:
Two flakes in
test/e2e/tests/test_vpc_endpoint.py, both seen in the requiredec2-controller-testjob on PRs that do not change this controller. The issue has the logs.test_create_delete,test_crud_tagsandtest_update_subnetsdeleted the CR with the acktest default wait: one check, 5 seconds after the delete. On fix(runtime): keep the CR's spec when a delete fails runtime#286 aDeleteVpcEndpointscall took 6.6 seconds and the test failed withassert deleted is True, although the controller removed the finalizer a moment later. These calls now pass3, 10, like the fixtures in this file and most of the suite.simple_vpc_endpointandmodify_vpc_endpointreturned the CR as soon as it had astatus. On Update OWNERS_ALIASES code-generator#764 the create was failing withVpcEndpointLimitExceeded, the status held only conditions, and the test failed withKeyError: 'vpcEndpointID'. The fixtures now wait forACK.ResourceSynced=True, up to 100 seconds, and read the CR again. If the endpoint still does not exist by then, the fixture fails on that wait, and acktest logs the condition's message.The other asserted deletes in the suite get the same
3, 10in #410.Checked with
python3 -m py_compile; the e2e suite itself runs only in CI.By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
🤖 Generated with Claude Code