Skip to content

Commit bc9b20a

Browse files
committed
fix: CI failures from govulncheck and Windows test
- Update Go version to 1.24.11 to fix crypto/x509 vulnerabilities (GO-2025-4175, GO-2025-4155) - Fix TestParseCue_AbsolutePaths on Windows by using platform-appropriate absolute paths
1 parent 08bacea commit bc9b20a

File tree

2 files changed

+16
-4
lines changed

2 files changed

+16
-4
lines changed

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
module github.com/ZaparooProject/go-gameid
22

3-
go 1.24
3+
go 1.24.11

iso9660/cue_test.go

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -161,8 +161,20 @@ func TestParseCue_AbsolutePaths(t *testing.T) {
161161
}
162162
defer func() { _ = os.RemoveAll(tmpDir) }()
163163

164+
// Create a platform-appropriate absolute path for testing
165+
// On Windows, use the temp directory as the base for an absolute path
166+
// On Unix, use a typical Unix absolute path
167+
var absPath string
168+
if filepath.Separator == '\\' {
169+
// Windows: use tmpDir as an absolute path base
170+
absPath = filepath.Join(tmpDir, "absolute", "path", "game.bin")
171+
} else {
172+
// Unix: use a Unix-style absolute path
173+
absPath = "/absolute/path/game.bin"
174+
}
175+
164176
// CUE with absolute path
165-
cueContent := `FILE "/absolute/path/game.bin" BINARY
177+
cueContent := `FILE "` + absPath + `" BINARY
166178
TRACK 01 MODE1/2352
167179
INDEX 01 00:00:00`
168180

@@ -181,7 +193,7 @@ TRACK 01 MODE1/2352
181193
}
182194

183195
// Absolute paths should be preserved
184-
if cue.BinFiles[0] != "/absolute/path/game.bin" {
185-
t.Errorf("BinFiles[0] = %q, want %q", cue.BinFiles[0], "/absolute/path/game.bin")
196+
if cue.BinFiles[0] != absPath {
197+
t.Errorf("BinFiles[0] = %q, want %q", cue.BinFiles[0], absPath)
186198
}
187199
}

0 commit comments

Comments
 (0)