chore: update Go from 1.25.6 to 1.25.7 (#22042)

This commit is contained in:
Jon Ayers
2026-02-17 22:31:20 -06:00
committed by GitHub
parent bab99db9e7
commit e82edf1b6b
5 changed files with 23 additions and 18 deletions
+16 -11
View File
@@ -16,19 +16,24 @@ import (
// During tests on darwin we hit the max path length limit for unix sockets
// pretty easily in the default location, so this function uses /tmp instead to
// get shorter paths.
//
// On Linux, we also hit this limit on GitHub Actions runners where TMPDIR is
// set to a long path like /home/runner/work/_temp/go-tmp/.
func TempDirUnixSocket(t *testing.T) string {
t.Helper()
if runtime.GOOS == "darwin" {
testName := strings.ReplaceAll(t.Name(), "/", "_")
dir, err := os.MkdirTemp("/tmp", testName)
require.NoError(t, err, "create temp dir for gpg test")
t.Cleanup(func() {
err := os.RemoveAll(dir)
assert.NoError(t, err, "remove temp dir", dir)
})
return dir
// Windows doesn't have the same unix socket path length limits,
// and callers of this function are generally gated to !windows.
if runtime.GOOS == "windows" {
return t.TempDir()
}
return t.TempDir()
testName := strings.ReplaceAll(t.Name(), "/", "_")
dir, err := os.MkdirTemp("/tmp", testName)
require.NoError(t, err, "create temp dir for unix socket test")
t.Cleanup(func() {
err := os.RemoveAll(dir)
assert.NoError(t, err, "remove temp dir", dir)
})
return dir
}