Documentation ¶
Index ¶
- func IsJpeg(path string) bool
- func MountPoint() (string, func(), error)
- func MountTestFs(mountPoint string, root fs.InodeEmbedder) (*fuse.Server, error)
- func ToGoldFileFormat(treeInfo []FileInfo, mountPoint string, libraryRoot string)
- func VerifyJpegAreValid(t TestingT, fileInfos []FileInfo)
- type FileInfo
- type TestingT
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsJpeg ¶
IsJpeg is a simple test tool to read in the specified file to see if it is a jpeg photo. This is intended to give us good enough confidence that the photo at that path had symlinking setup correctly by photofs. As long as we can read it as a valid jpeg then the symlinking worked. (we are also verifying the link target, this is just one added layer to make sure we can actually read the photo too.)
func MountPoint ¶
func MountTestFs ¶ added in v0.2.0
func ToGoldFileFormat ¶ added in v0.2.0
ToGoldFileFormat does some processing of the "Walk" results so it may be stored as a "gold" file test result file
func VerifyJpegAreValid ¶ added in v0.2.0
VerifyJpegAreValid verifies that all of the JPEG files in the provided file infos are valid JPEG files.
Types ¶
type FileInfo ¶
type FileInfo struct { Path string `json:"path"` Mode fs.FileMode `json:"mode"` LinkTarget string `json:"linkTarget,omitempty"` }
func GetOrUpdateGoldFile ¶ added in v0.2.0
GetOrUpdateGoldFile gets an existing gold file or takes the actual file info and uses it to overwrite the existing gold file.