From adced548410a4a185c9b8916e3a8dcf2d5857a2f Mon Sep 17 00:00:00 2001 From: Ryan McKinley Date: Wed, 19 Feb 2025 18:26:55 +0300 Subject: [PATCH] fix lint --- pkg/tests/apis/provisioning/provisioning_test.go | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/pkg/tests/apis/provisioning/provisioning_test.go b/pkg/tests/apis/provisioning/provisioning_test.go index c6a494e222d..6641d1082fe 100644 --- a/pkg/tests/apis/provisioning/provisioning_test.go +++ b/pkg/tests/apis/provisioning/provisioning_test.go @@ -20,6 +20,8 @@ import ( "k8s.io/apimachinery/pkg/runtime/schema" gh "github.com/google/go-github/v66/github" + ghmock "github.com/migueleliasweb/go-github-mock/src/mock" + dashboard "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1" folder "github.com/grafana/grafana/pkg/apis/folder/v0alpha1" provisioning "github.com/grafana/grafana/pkg/apis/provisioning/v0alpha1" @@ -29,7 +31,6 @@ import ( "github.com/grafana/grafana/pkg/tests/apis" "github.com/grafana/grafana/pkg/tests/testinfra" "github.com/grafana/grafana/pkg/tests/testsuite" - ghmock "github.com/migueleliasweb/go-github-mock/src/mock" ) func TestMain(m *testing.M) { @@ -97,37 +98,37 @@ func TestIntegrationProvisioning(t *testing.T) { ghmock.WithRequestMatchHandler( ghmock.GetUser, http.HandlerFunc(func(w http.ResponseWriter, _ *http.Request) { - w.Write(ghmock.MustMarshal(&gh.User{})) + _, _ = w.Write(ghmock.MustMarshal(&gh.User{})) }), ), ghmock.WithRequestMatchHandler( ghmock.GetReposHooksByOwnerByRepo, http.HandlerFunc(func(w http.ResponseWriter, _ *http.Request) { - w.Write(ghmock.MustMarshal([]*gh.Hook{})) + _, _ = w.Write(ghmock.MustMarshal([]*gh.Hook{})) }), ), ghmock.WithRequestMatchHandler( ghmock.PostReposHooksByOwnerByRepo, http.HandlerFunc(func(w http.ResponseWriter, _ *http.Request) { - w.Write(ghmock.MustMarshal(&gh.Hook{})) + _, _ = w.Write(ghmock.MustMarshal(&gh.Hook{})) }), ), ghmock.WithRequestMatchHandler( ghmock.GetReposByOwnerByRepo, http.HandlerFunc(func(w http.ResponseWriter, _ *http.Request) { - w.Write(ghmock.MustMarshal(&gh.Repository{})) + _, _ = w.Write(ghmock.MustMarshal(&gh.Repository{})) }), ), ghmock.WithRequestMatchHandler( ghmock.GetReposBranchesByOwnerByRepoByBranch, http.HandlerFunc(func(w http.ResponseWriter, _ *http.Request) { - w.Write(ghmock.MustMarshal(&gh.Branch{})) + _, _ = w.Write(ghmock.MustMarshal(&gh.Branch{})) }), ), ghmock.WithRequestMatchHandler( ghmock.GetReposGitTreesByOwnerByRepoByTreeSha, http.HandlerFunc(func(w http.ResponseWriter, _ *http.Request) { - w.Write(ghmock.MustMarshal(&gh.Tree{})) + _, _ = w.Write(ghmock.MustMarshal(&gh.Tree{})) }), ), ghmock.WithRequestMatchHandler(