Mercurial > hg-stable
changeset 5074:e86788af599a
hghave: detect support for EOL in paths.
author | Patrick Mezard <pmezard@gmail.com> |
---|---|
date | Mon, 06 Aug 2007 09:57:23 +0200 |
parents | 4cd52978e188 |
children | 2184378b20b5 |
files | tests/hghave |
diffstat | 1 files changed, 10 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/tests/hghave Mon Aug 06 10:38:07 2007 +0200 +++ b/tests/hghave Mon Aug 06 09:57:23 2007 +0200 @@ -23,10 +23,20 @@ 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():