# HG changeset patch # User Patrick Mezard # Date 1186387043 -7200 # Node ID e86788af599a247fdbfe060386a6ed5038efdc8c # Parent 4cd52978e1888aa1bd92b8c21817bd9fd4032458 hghave: detect support for EOL in paths. diff --git a/tests/hghave b/tests/hghave --- a/tests/hghave +++ b/tests/hghave @@ -23,10 +23,20 @@ def has_executablebit(): finally: os.remove(path) +def has_eol_in_paths(): + try: + fd, path = tempfile.mkstemp(suffix='\n\r') + os.close(fd) + os.remove(path) + return True + except: + return False + checks = { "symlink": (has_symlink, "symbolic links"), "fifo": (has_fifo, "named pipes"), "execbit": (has_executablebit, "executable bit"), + "eol-in-paths": (has_eol_in_paths, "end-of-lines in paths"), } def list_features():