Skip to content
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

🐛 Remove exact path match from walkTemplate test #8019

Merged

Conversation

killianmuldoon
Copy link
Contributor

Remove the exact path for the testScheme from the walkTemplates test. This change also renames the test file to correct a typo.

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jan 30, 2023
@killianmuldoon killianmuldoon changed the title Remove exact path match from walkTemplate test 🐛 Remove exact path match from walkTemplate test Jan 30, 2023
@@ -130,7 +130,7 @@ func Test_WalkTemplates(t *testing.T) {
CommonResponse: runtimehooksv1.CommonResponse{
Status: runtimehooksv1.ResponseStatusFailure,
Message: "no kind \"Unknown\" is registered for version \"controlplane.cluster.x-k8s." +
"io/v1beta1\" in scheme \"pkg/runtime/scheme.go:100\"",
Copy link
Contributor Author

@killianmuldoon killianmuldoon Jan 30, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This issue was reported in slack where the path reported was "go/pkg/runtime.scheme.go". This can be safely changed without losing coverage. I'm currently digging to the bottom of how the path is generated to see why it might have ended up different here.

@mtougeron it would be great if you could outline how you had the packages set up, or whether this issue is hitting you on a clean main repo.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm on MacOS

$> pwd
/Users/tougeron/src/go/src/github.com/mtougeron/cluster-api
$> env | grep GO
GOPATH=/Users/tougeron/src/go

FWIW, I just tried without setting my GOPATH and it worked as expected.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting - I wonder if any other tests are dependent on using go modules 🤔

@sbueringer
Copy link
Member

Thx!

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jan 30, 2023
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 258b5f56cc47e640f75560a00d15946cd59bcca9

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: sbueringer

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jan 30, 2023
@k8s-ci-robot k8s-ci-robot merged commit d55849a into kubernetes-sigs:main Jan 30, 2023
@k8s-ci-robot k8s-ci-robot added this to the v1.4 milestone Jan 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants