fix(auto): resolve symlinked directory before walk (#8032)

This commit is contained in:
Ville Vesilehto
2026-04-09 00:38:01 +03:00
committed by GitHub
parent 489a4f8703
commit 4c71636a71
3 changed files with 51 additions and 1 deletions

View File

@@ -56,6 +56,13 @@ func TestSymlinks(t *testing.T) {
if err != nil {
t.Fatal(err)
}
// Resolve tempdir to handle platforms where temp paths contain symlinks
// (e.g., macOS where /var -> /private/var). Walk resolves the directory
// via EvalSymlinks, so stored paths use the resolved prefix.
tempdir, err = filepath.EvalSymlinks(tempdir)
if err != nil {
t.Fatal(err)
}
ldr := loader{
directory: tempdir,