From 72da7054b2668c838dac133fac87b25a1eef98b7 Mon Sep 17 00:00:00 2001 From: jasondborneman Date: Fri, 12 Jan 2024 12:44:39 -0500 Subject: [PATCH] Linting Fixes 1 --- example/weather/services/tester/run_tests.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/example/weather/services/tester/run_tests.go b/example/weather/services/tester/run_tests.go index 64ed1e5..551f846 100644 --- a/example/weather/services/tester/run_tests.go +++ b/example/weather/services/tester/run_tests.go @@ -86,11 +86,11 @@ func matchTestFilter(ctx context.Context, test string, testMap map[string]func(c g, err := glob.Compile(test) if err != nil { _ = logError(ctx, err) - err = errors.New(fmt.Sprintf("wildcard glob [%s] did not compile: %v", test, err)) + err = fmt.Errorf("wildcard glob [%s] did not compile: %v", test, err) return testMatches, err } i := 0 - for testName, _ := range testMap { + for testName := range testMap { match = g.Match(testName) if match { testMatches = append(testMatches, testMap[testName]) @@ -143,7 +143,7 @@ func (svc *Service) runTests(ctx context.Context, p *gentester.TesterPayload, te g, err := glob.Compile(excludeTest) if err != nil { _ = logError(ctx, err) - err = errors.New(fmt.Sprintf("wildcard glob [%s] did not compile: %v", excludeTest, err)) + err = fmt.Errorf("wildcard glob [%s] did not compile: %v", excludeTest, err) return nil, gentester.MakeWildcardCompileError(err) } wildcardMatch = wildcardMatch || g.Match(testName)