From ea00dc0210a9956d4b9d4d135a92b9f5f55329af Mon Sep 17 00:00:00 2001 From: Adam Chalkley Date: Tue, 21 Nov 2023 05:41:18 -0600 Subject: [PATCH] Hotfix goconst linting errors for test cases Add nolint directive to permit duplicate `plugin.ServiceOutput` content between test cases. --- exported_test.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/exported_test.go b/exported_test.go index 027942d..7db17ee 100644 --- a/exported_test.go +++ b/exported_test.go @@ -66,6 +66,7 @@ func TestPluginOutputIsValid(t *testing.T) { 90, ) + //nolint:goconst plugin.ServiceOutput = "OK: Datastore HUSVM-DC1-vol6 space usage (0 VMs)" + " is 0.01% of 18.0TB with 18.0TB remaining" + @@ -160,6 +161,7 @@ func TestPerformanceDataIsOnSameLineAsServiceOutput(t *testing.T) { // os.Exit calls break tests plugin.SkipOSExit() + //nolint:goconst plugin.ServiceOutput = "OK: Datastore HUSVM-DC1-vol6 space usage (0 VMs)" + " is 0.01% of 18.0TB with 18.0TB remaining" + @@ -222,6 +224,7 @@ func TestPerformanceDataIsAfterLongServiceOutput(t *testing.T) { 90, ) + //nolint:goconst plugin.ServiceOutput = "OK: Datastore HUSVM-DC1-vol6 space usage (0 VMs)" + " is 0.01% of 18.0TB with 18.0TB remaining" +