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
enhance assertions in test/e2e/windows #110303
enhance assertions in test/e2e/windows #110303
Conversation
@hunknownz: This issue is currently awaiting triage. If a SIG or subproject determines this is a relevant issue, they will accept it by applying the The 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. |
Hi @hunknownz. Thanks for your PR. I'm waiting for a kubernetes 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. |
/assign @pohly |
test/e2e/windows/host_process.go
Outdated
framework.ExpectEqual(beforeMetrics.StartedContainersErrorCount < afterMetrics.StartedContainersErrorCount, true, "Count of started HostProcess errors containers should increase") | ||
framework.ExpectEqual(beforeMetrics.StartedInitContainersCount < afterMetrics.StartedInitContainersCount, true, "Count of started HostProcess init containers should increase") | ||
framework.ExpectEqual(beforeMetrics.StartedInitContainersErrorCount < afterMetrics.StartedInitContainersErrorCount, true, "Count of started HostProcess errors init containers should increase") | ||
gomega.Expect(beforeMetrics.StartedContainersCount).To(gomega.BeNumerically("<", afterMetrics.StartedContainersCount), fmt.Sprintf("Count of started HostProcess containers should increase: >= %v", afterMetrics.StartedContainersCount)) |
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.
Here and below the gomega.BeNumerically already takes care of printing the two values, so they don't need to be included in the explanation.
Also note that Expect does the printf formatting itself, so fmt.Sprintf would not be needed here.
Signed-off-by: hunknownz <klercc37@gmail.com>
fda63bc
to
fdb43cc
Compare
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.
/lgtm
/assign @marosset |
@pohly which owner should I assign? |
I can take a look today. /test pull-kubernetes-e2e-capz-windows-containerd |
@hunknownz: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. 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. I understand the commands that are listed here. |
The tests that did fail are known issues are should be addressed with #110235 |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: hunknownz, marosset, pohly 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 |
Thanks |
Signed-off-by: hunknownz klercc37@gmail.com
What type of PR is this?
/kind cleanup
What this PR does / why we need it:
Better output for developers when tests fail.
Which issue(s) this PR fixes:
Fixes part of #105678
Special notes for your reviewer:
After this PR:
Does this PR introduce a user-facing change?
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.: