Mercurial > public > mercurial-scm > hg
diff tests/hghave.py @ 31678:1ed57a7dd904
statfs: make getfstype() raise OSError
It's better for getfstype() function to not suppress an error. Callers can
handle it as necessary. Now "hg debugfsinfo" will report OSError.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Sat, 25 Mar 2017 17:25:23 +0900 |
parents | b33e352c365c |
children | ebaada96aec3 |
line wrap: on
line diff
--- a/tests/hghave.py Sat Mar 25 17:24:11 2017 +0900 +++ b/tests/hghave.py Sat Mar 25 17:25:23 2017 +0900 @@ -349,7 +349,10 @@ @check("hardlink-whitelisted", "hardlinks on whitelisted filesystems") def has_hardlink_whitelisted(): from mercurial import util - fstype = util.getfstype('.') + try: + fstype = util.getfstype('.') + except OSError: + return False return fstype in util._hardlinkfswhitelist @check("rmcwd", "can remove current working directory")