Skip to content

Commit 51563ef

Browse files
committed
fix: tests runner
1 parent 3e50805 commit 51563ef

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

test/testshared/runner.go

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -372,7 +372,7 @@ func InstallGolangciLint(tb testing.TB) string {
372372

373373
// TODO(ldez) remove when we will run go1.23 on the CI.
374374
func forceDisableUnsupportedLinters(args []string) []string {
375-
if !isGoVersion("1.21") {
375+
if !isGoLessThan("1.22") {
376376
return args
377377
}
378378

@@ -414,7 +414,7 @@ func forceDisableUnsupportedLinters(args []string) []string {
414414
}
415415

416416
// TODO(ldez) remove when we will run go1.23 on the CI.
417-
func isGoVersion(tag string) bool {
417+
func isGoLessThan(tag string) bool {
418418
vRuntime, err := hcversion.NewVersion(strings.TrimPrefix(runtime.Version(), "go"))
419419
if err != nil {
420420
return false
@@ -425,5 +425,7 @@ func isGoVersion(tag string) bool {
425425
return false
426426
}
427427

428-
return vRuntime.GreaterThanOrEqual(vTag)
428+
println(vRuntime.LessThanOrEqual(vTag))
429+
430+
return vRuntime.LessThan(vTag)
429431
}

0 commit comments

Comments
 (0)