Skip to content

Commit 9c54d2b

Browse files
authored
Start testing against Go 1.25 (#1014)
Start testing against Go 1.25. I didn't change the `go.mod` version. I figure it's probably fine to leave that as low as is convenient for us to maintain as a courtesy to those at companies where it's harder to upgrade.
1 parent 38b69b1 commit 9c54d2b

2 files changed

Lines changed: 22 additions & 11 deletions

File tree

.github/workflows/ci.yaml

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,20 @@ jobs:
2727
runs-on: ubuntu-latest
2828
strategy:
2929
matrix:
30-
# Run the 4 latest Postgres versions against the latest Go version:
31-
go-version:
32-
- "1.24"
33-
postgres-version: [14, 15, 16, 17]
3430
include:
35-
# Also run previous Go version against the latest Postgres version:
31+
# Run the 4 latest Postgres versions against the latest Go version:
32+
- go-version: "1.25"
33+
postgres-version: 17
34+
- go-version: "1.25"
35+
postgres-version: 16
36+
- go-version: "1.25"
37+
postgres-version: 15
38+
- go-version: "1.25"
39+
postgres-version: 14
40+
41+
# Also run a couple previous Go versions against the latest Postgres version:
42+
- go-version: "1.24"
43+
postgres-version: 17
3644
- go-version: "1.23"
3745
postgres-version: 17
3846
fail-fast: false

cmd/river/rivercli/river_cli_test.go

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -179,8 +179,9 @@ func TestBaseCommandSetIntegration(t *testing.T) {
179179

180180
buildInfo, _ := debug.ReadBuildInfo()
181181

182-
require.Equal(t, strings.TrimSpace(fmt.Sprintf(`
183-
River version (unknown)
182+
// `devel` on 1.25, `unknown` on versions previous to that
183+
require.Regexp(t, strings.TrimSpace(fmt.Sprintf(`
184+
River version \((devel|unknown)\)
184185
Built with %s
185186
`, buildInfo.GoVersion)), strings.TrimSpace(bundle.out.String()))
186187
})
@@ -195,8 +196,9 @@ Built with %s
195196

196197
buildInfo, _ := debug.ReadBuildInfo()
197198

198-
require.Equal(t, strings.TrimSpace(fmt.Sprintf(`
199-
River version (unknown)
199+
// `devel` on 1.25, `unknown` on versions previous to that
200+
require.Regexp(t, strings.TrimSpace(fmt.Sprintf(`
201+
River version \((devel|unknown)\)
200202
Built with %s
201203
`, buildInfo.GoVersion)), strings.TrimSpace(bundle.out.String()))
202204
})
@@ -502,8 +504,9 @@ func TestVersion(t *testing.T) {
502504

503505
buildInfo, _ := debug.ReadBuildInfo()
504506

505-
require.Equal(t, strings.TrimSpace(fmt.Sprintf(`
506-
River version (unknown)
507+
// `devel` on 1.25, `unknown` on versions previous to that
508+
require.Regexp(t, strings.TrimSpace(fmt.Sprintf(`
509+
River version \((devel|unknown)\)
507510
Built with %s
508511
`, buildInfo.GoVersion)), strings.TrimSpace(bundle.buf.String()))
509512
})

0 commit comments

Comments
 (0)