fix test failure on windows

"a:" failed; this test wants a relative filename so isDrive avoids it

Note that on linux, isDrive "/foo" is true. This test also filters out
absolute paths already, so that is ok.

This commit was sponsored by Brock Spratlen on Patreon.
This commit is contained in:
Joey Hess 2020-11-26 11:48:52 -04:00
parent 79135e4a92
commit e92117bfd0
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38

View file

@ -83,7 +83,7 @@ prop_viewedFile_roundtrips :: TestableFilePath -> Bool
prop_viewedFile_roundtrips tf
-- Relative filenames wanted, not directories.
| any (isPathSeparator) (end f ++ beginning f) = True
| isAbsolute f = True
| isAbsolute f || isDrive f = True
| otherwise = dir == dirFromViewedFile (viewedFileFromReference f)
where
f = fromTestableFilePath tf