From fbe323be1ea3a2297ea45b41e8513cbea2ce4071 Mon Sep 17 00:00:00 2001 From: Nahshon Unna-Tsameret Date: Mon, 11 Jul 2022 08:16:55 +0300 Subject: [PATCH] Remove all the dependencies in ginkgo & gomega By setting the Analyzer's RunDespiteErrors field to true, the type check is skiped and the linter can work without the need to actually import ginkgo and gomega. This will ease the integration with other applications, such as golangci-lint. --- ginkgo_linter.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ginkgo_linter.go b/ginkgo_linter.go index 6b532b4..226ae74 100644 --- a/ginkgo_linter.go +++ b/ginkgo_linter.go @@ -35,7 +35,8 @@ For example: Expect(len(x).Should(Equal(1)) This should be replaced with: Expect(x).Should(HavelLen(1)`, - Run: run, + Run: run, + RunDespiteErrors: true, } const (