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
Enable import-boss check for integration test #89235
Conversation
"Rules": [ | ||
{ | ||
"SelectorRegexp": "k8s[.]io/kubernetes/test/e2e", | ||
"AllowedPrefixes": [] |
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.
This means test/integration
code is not allowed to import any code under test/e2e/
.
/test pull-kubernetes-verify |
Now we have remaining one as
|
/retitle Enable import-boss check for integration test |
/cc @andrewsykim |
/retest |
@oomichi thanks for doing this! Wait for other reviewers' feedback. |
/lgtm |
/assign |
hack/verify-import-boss.sh
Outdated
@@ -30,7 +30,7 @@ kube::golang::setup_env | |||
|
|||
make -C "${KUBE_ROOT}" WHAT=vendor/k8s.io/code-generator/cmd/import-boss | |||
|
|||
packages=("k8s.io/kubernetes/pkg/..." "k8s.io/kubernetes/cmd/..." "k8s.io/kubernetes/plugin/..." "k8s.io/kubernetes/test/e2e/framework/...") | |||
packages=("k8s.io/kubernetes/pkg/..." "k8s.io/kubernetes/cmd/..." "k8s.io/kubernetes/plugin/..." "k8s.io/kubernetes/test/e2e/framework/..." "k8s.io/kubernetes/test/integration/...") |
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.
can you put these on newlines and alphasort for ease of diff going forward?
packages=("k8s.io/kubernetes/pkg/..." "k8s.io/kubernetes/cmd/..." "k8s.io/kubernetes/plugin/..." "k8s.io/kubernetes/test/e2e/framework/..." "k8s.io/kubernetes/test/integration/...") | |
packages=( | |
"k8s.io/kubernetes/cmd/..." | |
"k8s.io/kubernetes/pkg/..." | |
# etc.. | |
) |
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.
@spiffxp Thanks for your review.
That is a good idea to maintain many places.
Integration tests imported e2e test code and the dependency made two drawbacks: - Hard to move test/e2e/framework into staging (kubernetes#74352) - Need to run integration tests always even if PRs are just changing e2e test code This enables import-boss check for blocking such dependency.
I tried running this locally via |
/priority important-soon |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: oomichi, spiffxp 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 |
That is a nice point. |
What type of PR is this?
/kind cleanup
What this PR does / why we need it:
Integration tests imported e2e test code and the dependency made two drawbacks:
This enables import-boss check for blocking such dependency.
Which issue(s) this PR fixes:
Fixes #89185
Does this PR introduce a user-facing change?: