diff --git a/pkg/authorization/rewrite/rewrite_test.go b/pkg/authorization/rewrite/rewrite_test.go index 0526cabdb..ee23433d4 100644 --- a/pkg/authorization/rewrite/rewrite_test.go +++ b/pkg/authorization/rewrite/rewrite_test.go @@ -17,7 +17,7 @@ package rewrite_test import ( "context" - "fmt" + "errors" "testing" "github.com/brancz/kube-rbac-proxy/pkg/authorization/rewrite" @@ -136,7 +136,7 @@ func TestRewritingAuthorizer(t *testing.T) { reason := "some error" // shouldn't happen, but just in case - return authorizer.DecisionAllow, reason, fmt.Errorf(reason) + return authorizer.DecisionAllow, reason, errors.New(reason) }, }, attrGen: simpleAttributesGenerator,