Lines Matching refs:stat
33 …assertStat := func(t *testing.T, stat os.FileInfo, err error, wantName string, wantMode os.FileMod…
39 if g, w := stat.Name(), wantName; g != w {
42 if g, w := stat.Mode(), wantMode; g != w {
53 stat, err := filesystem.Lstat("/tmp/links/dir")
54 assertStat(t, stat, err, "dir", os.ModeSymlink)
56 stat, err = filesystem.Stat("/tmp/links/dir")
57 assertStat(t, stat, err, "realdir", os.ModeDir)
59 stat, err = filesystem.Lstat("/tmp/links/file")
60 assertStat(t, stat, err, "file", os.ModeSymlink)
62 stat, err = filesystem.Stat("/tmp/links/file")
63 assertStat(t, stat, err, "hi.txt", 0)
65 stat, err = filesystem.Lstat("/tmp/links/broken")
66 assertStat(t, stat, err, "broken", os.ModeSymlink)
68 stat, err = filesystem.Stat("/tmp/links/broken")
71 stat, err = filesystem.Lstat("/tmp/links/recursive")
72 assertStat(t, stat, err, "recursive", os.ModeSymlink)
74 stat, err = filesystem.Stat("/tmp/links/recursive")