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: skip AllNodesReady when the test skipped framework initialization #113097
Conversation
This addresses a problem caused by kubernetes#112043: because the AfterEach which invokes AllNodesReady always runs, including tests that skipped early, those tests ran into a nil pointer access. This increased the size of log files. The tests still worked.
@pohly: 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. |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: 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 |
No panic in pull-kubernetes-e2e-kind. |
@@ -30,6 +30,12 @@ func init() { | |||
framework.NewFrameworkExtensions = append(framework.NewFrameworkExtensions, | |||
func(f *framework.Framework) { | |||
ginkgo.AfterEach(func() { | |||
if f.ClientSet == nil { |
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.
heh, I think that we talked about this check before and we couldn't understand why it was there 🙃
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.
Source code comments matter... hopefully it is clear now. 😄
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 |
What type of PR is this?
/kind bug
/kind failing-test
/kind regression
What this PR does / why we need it:
This addresses a problem caused by
#112043: because the AfterEach which invokes AllNodesReady always runs, including tests that skipped early, those tests ran into a nil pointer access. This increased the size of log files. The tests still worked.
Which issue(s) this PR fixes:
Fixes #112996
Does this PR introduce a user-facing change?