From 413f9552bdecaf5c95886cde6917d34658975a48 Mon Sep 17 00:00:00 2001 From: bm-skutzke Date: Mon, 8 Sep 2025 10:33:49 +0200 Subject: [PATCH 1/2] feat: changed minimum go version from 1.25.0 to 1.24.0 --- go.mod | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/go.mod b/go.mod index fa5cf28..5b1f5b5 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/bettermarks/composite-action-lint -go 1.25.0 +go 1.24.0 require ( github.com/rhysd/actionlint v1.7.7 From df3d2b014e135e8b335b7ecb4e1cd4acd543a390 Mon Sep 17 00:00:00 2001 From: Daniel Golding Date: Mon, 8 Sep 2025 14:01:26 +0200 Subject: [PATCH 2/2] test: remove t.Output() which is new in 1.25 --- command_test.go | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/command_test.go b/command_test.go index b517f64..750afd0 100644 --- a/command_test.go +++ b/command_test.go @@ -1,6 +1,7 @@ package compositeactionlint import ( + "bytes" "testing" "github.com/stretchr/testify/assert" @@ -18,9 +19,12 @@ func TestCommandMain_Ok(t *testing.T) { for _, filepath := range files { t.Run(filepath, func(t *testing.T) { - c := Command{Stdout: t.Output(), Stderr: t.Output()} + // Replace with t.Output() from go 1.25 + var testOut bytes.Buffer + c := Command{Stdout: &testOut, Stderr: &testOut} exitCode := c.Main([]string{argv0, filepath}) + t.Log(testOut.String()) assert.Equal(t, 0, exitCode) }) } @@ -35,9 +39,12 @@ func TestCommandMain_BadActions(t *testing.T) { for _, filepath := range files { t.Run(filepath, func(t *testing.T) { - c := Command{Stdout: t.Output(), Stderr: t.Output()} + // Replace with t.Output() from go 1.25 + var testOut bytes.Buffer + c := Command{Stdout: &testOut, Stderr: &testOut} exitCode := c.Main([]string{argv0, filepath}) + t.Log(testOut.String()) assert.Equal(t, 1, exitCode) }) }