From b508b0fc315d1576bd4d3648614c0a771e2939c8 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Fri, 2 Sep 2022 23:55:51 +0200 Subject: [PATCH] linting: ST1017: don't use Yoda conditions (stylecheck) opts/envfile_test.go:157:5: ST1017: don't use Yoda conditions (stylecheck) if 1 != len(variables) { ^ Signed-off-by: Sebastiaan van Stijn --- opts/envfile_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opts/envfile_test.go b/opts/envfile_test.go index de84410a05..be97373fcb 100644 --- a/opts/envfile_test.go +++ b/opts/envfile_test.go @@ -154,7 +154,7 @@ HOME t.Fatal("the HOME variable is not properly imported as the first variable (but it is the only one to import)") } - if 1 != len(variables) { + if len(variables) != 1 { t.Fatal("exactly one variable is imported (as the other one is not set at all)") } }