-
Notifications
You must be signed in to change notification settings - Fork 34
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
e2e: Change deprecated vm Running API #453
base: main
Are you sure you want to change the base?
e2e: Change deprecated vm Running API #453
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
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.
Thank you for the PR @RamLavi.
tests/virtual_machines_test.go
Outdated
vm1, err = testClient.VirtClient.VirtualMachine(vm1.Namespace).Create(context.TODO(), vm1) | ||
Expect(err).ToNot(HaveOccurred()) | ||
Expect(err).ToNot(HaveOccurred(), "1") |
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.
What is the meaning of "1"?
Is it a leftover?
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.
leftover :) thanks!
tests/virtual_machines_test.go
Outdated
conflictingVM, err = testClient.VirtClient.VirtualMachine(conflictingVM.Namespace).Create(context.TODO(), conflictingVM) | ||
Expect(err).ToNot(HaveOccurred()) | ||
Expect(err).ToNot(HaveOccurred(), "2") |
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.
Same.
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.
Removed
tests/tests.go
Outdated
@@ -91,11 +91,11 @@ func removeTestNamespaces() { | |||
Should(BeTrue(), "Namespace %s haven't been deleted within the given timeout", TestNamespace) | |||
} | |||
|
|||
func CreateVmObject(namespace string, running bool, interfaces []kubevirtv1.Interface, networks []kubevirtv1.Network) *kubevirtv1.VirtualMachine { | |||
func CreateVmObject(namespace string, strategy kubevirtv1.VirtualMachineRunStrategy, interfaces []kubevirtv1.Interface, networks []kubevirtv1.Network) *kubevirtv1.VirtualMachine { |
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.
I haven't noticed a call to this function with a strategy
value different from RunStrategyHalted
.
Please consider dropping the parameter.
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.
DONE
@orelmisan: changing LGTM is restricted to collaborators In response to this:
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-sigs/prow repository. |
Moreover, the parameter is always the same to pin it on CreateVmObject itself. Signed-off-by: Ram Lavi <[email protected]>
5e724b8
to
64fd6c3
Compare
Change: Address @orelmisan 's review |
@RamLavi it seems like unrelated changes had leaked into the PR. |
@RamLavi: The following test failed, say
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-sigs/prow repository. I understand the commands that are listed here. |
What this PR does / why we need it:
This PR fixed e2e infra that uses old kubevirt VM Running API.
Special notes for your reviewer:
Release note: