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

🐛 Downgrade golangci-lint to address gci autolint issues #6351

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/golangci-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,5 @@ jobs:
- name: golangci-lint
uses: golangci/golangci-lint-action@v2
with:
version: v1.45.2
version: v1.44.0
working-directory: ${{matrix.working-directory}}
7 changes: 5 additions & 2 deletions internal/webhooks/cluster_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@ func TestClusterDefaultNamespaces(t *testing.T) {
},
}
webhook := &Cluster{}
t.Run("for Cluster", customDefaultValidateTest(ctx, c, webhook))
tFunc := customDefaultValidateTest(ctx, c, webhook)

t.Run("for Cluster", tFunc)
g.Expect(webhook.Default(ctx, c)).To(Succeed())

g.Expect(c.Spec.InfrastructureRef.Namespace).To(Equal(c.Namespace))
Expand Down Expand Up @@ -348,7 +350,8 @@ func TestClusterDefaultTopologyVersion(t *testing.T) {

// Create the webhook and add the fakeClient as its client.
webhook := &Cluster{Client: fakeClient}
t.Run("for Cluster", customDefaultValidateTest(ctx, c, webhook))
tFunc := customDefaultValidateTest(ctx, c, webhook)
t.Run("for Cluster", tFunc)
g.Expect(webhook.Default(ctx, c)).To(Succeed())

g.Expect(c.Spec.Topology.Version).To(HavePrefix("v"))
Expand Down
4 changes: 3 additions & 1 deletion internal/webhooks/clusterclass_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,9 @@ func TestClusterClassDefaultNamespaces(t *testing.T) {

// Create the webhook and add the fakeClient as its client.
webhook := &ClusterClass{Client: fakeClient}
t.Run("for ClusterClass", customDefaultValidateTest(ctx, in, webhook))
tFunc := customDefaultValidateTest(ctx, in, webhook)

t.Run("for ClusterClass", tFunc)

g := NewWithT(t)
g.Expect(webhook.Default(ctx, in)).To(Succeed())
Expand Down
2 changes: 2 additions & 0 deletions util/container/image.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,10 @@ limitations under the License.
package container

import (

// Import the crypto sha256 algorithm for the docker image parser to work
_ "crypto/sha256"

// Import the crypto/sha512 algorithm for the docker image parser to work with 384 and 512 sha hashes
_ "crypto/sha512"
"fmt"
Expand Down