-
Notifications
You must be signed in to change notification settings - Fork 807
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add e2e test for volume resizing #705
add e2e test for volume resizing #705
Conversation
Hi @AndyXiangLi. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions 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/test-infra repository. |
/ok-to-test |
516e850
to
15aec3c
Compare
Pull Request Test Coverage Report for Build 1509
💛 - Coveralls |
updatedSize := updatedPvc.Spec.Resources.Requests["storage"] | ||
|
||
By("Wait for resize to complete") | ||
time.Sleep(30 * time.Second) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How did you come up with this number? Can we do this incrementally? Check every 5 seconds and give up after 1 minute for example.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah from my observation, it usually takes about 10s to have pv updated, so I put 30 seconds there. It is a good point to keep tracking the status instead of waiting, it is updated now
da63679
to
f1afc5a
Compare
for start := time.Now(); time.Since(start) < timeout; time.Sleep(interval) { | ||
newPv, _ := c.CoreV1().PersistentVolumes().Get(pvName, metav1.GetOptions{}) | ||
newPvSize := newPv.Spec.Capacity["storage"] | ||
if desiredSize.Equal(newPvSize) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you also need to return an error if they're not equal, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, it will return error if they are not equal and timeout at line 91
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah I see we can't exit early.
f1afc5a
to
e899154
Compare
/retest |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: AndyXiangLi, ayberk The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/retest |
/test pull-aws-ebs-csi-driver-e2e-single-az |
e899154
to
c5eba4f
Compare
/lgtm |
@ayberk @AndyXiangLi why are we doing this? We already had e2e via testsuites of CSI driver. I don't think we need more e2e (or if anything is missing it should be added to k/k repo). |
Can you point me to the e2e tests on the k/k repo? I'll make sure all new tests go there instead. |
here we go - https://github.com/kubernetes/kubernetes/blob/master/test/e2e/storage/testsuites/volume_expand.go We should be running these tests as part of this driver's e2e. |
Is this a bug fix or adding new feature?
Fixes #316
What is this PR about? / Why do we need it?
Add e2e test for volume resizing