fix test case on windows

"a:" is an absolute path, so viewedfile test cannot be run on it.
This commit is contained in:
Joey Hess 2014-12-30 16:04:06 -04:00
parent ed21043ab7
commit 402bfff665

View file

@ -70,6 +70,7 @@ prop_viewedFile_roundtrips :: FilePath -> Bool
prop_viewedFile_roundtrips f
-- Relative filenames wanted, not directories.
| any (isPathSeparator) (end f ++ beginning f) = True
| isAbsolute f = True
| otherwise = dir == dirFromViewedFile (viewedFileFromReference f)
where
dir = joinPath $ beginning $ splitDirectories f