fs: inline ExtendedStat

This commit is contained in:
Michael Eischer
2024-11-03 16:01:59 +01:00
parent 806fa534ce
commit 641390103d
22 changed files with 121 additions and 205 deletions

View File

@@ -84,13 +84,13 @@ func checkMetadata(t *testing.T, f File, path string, follow bool, nodeType rest
fi2, err = os.Lstat(path)
}
rtest.OK(t, err)
assertFIEqual(t, fi2, fi)
assertFIEqual(t, fi2, fi.FileInfo)
node, err := f.ToNode(false)
rtest.OK(t, err)
// ModTime is likely unique per file, thus it provides a good indication that it is from the correct file
rtest.Equals(t, fi.ModTime(), node.ModTime, "node ModTime")
rtest.Equals(t, fi.ModTime, node.ModTime, "node ModTime")
rtest.Equals(t, nodeType, node.Type, "node Type")
}