From 64b0cb1967a8517df0d21accb51adf8d0f4edafd Mon Sep 17 00:00:00 2001 From: Nadia Santalla Date: Mon, 16 Dec 2024 12:03:00 +0100 Subject: [PATCH] chore: rename add err prefix to unsupportedCheckType error Makes the linter happy --- internal/prober/prober.go | 4 ++-- internal/prober/prober_test.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/internal/prober/prober.go b/internal/prober/prober.go index d94709659..cdb3cfcb7 100644 --- a/internal/prober/prober.go +++ b/internal/prober/prober.go @@ -24,7 +24,7 @@ import ( "github.com/rs/zerolog" ) -const unsupportedCheckType = error_types.BasicError("unsupported check type") +const errUnsupportedCheckType = error_types.BasicError("unsupported check type") type Prober interface { Name() string @@ -119,7 +119,7 @@ func (f proberFactory) New(ctx context.Context, logger zerolog.Logger, check mod target = check.Target default: - return nil, "", unsupportedCheckType + return nil, "", errUnsupportedCheckType } return p, target, err diff --git a/internal/prober/prober_test.go b/internal/prober/prober_test.go index 371893458..4b46c9cc4 100644 --- a/internal/prober/prober_test.go +++ b/internal/prober/prober_test.go @@ -24,6 +24,6 @@ func TestProberFactoryCoverage(t *testing.T) { require.NoError(t, check.FromSM(sm.GetCheckInstance(checkType))) _, _, err := pf.New(ctx, testLogger, check) - require.NotErrorIs(t, err, unsupportedCheckType) + require.NotErrorIs(t, err, errUnsupportedCheckType) } }