Mercurial > hgsubversion
diff tests/test_fetch_command_regexes.py @ 25:99f8e4b535e9
svn 1.4 and 1.5 have different ideas of diff output for prop changes.
author | Augie Fackler <durin42@gmail.com> |
---|---|
date | Thu, 09 Oct 2008 23:37:22 -0500 |
parents | 48a44546c12f |
children | e2214c8fc91f |
line wrap: on
line diff
--- a/tests/test_fetch_command_regexes.py +++ b/tests/test_fetch_command_regexes.py @@ -29,18 +29,37 @@ Index: trunk/functional_tests/doc_tests/ =================================================================== """ +special_delta = """Index: delta +=================================================================== +--- delta(revision 0) ++++ delta(revision 9) +@@ -0,0 +1 @@ ++link alpha +\ No newline at end of file + +Property changes on: delta +___________________________________________________________________ +Name: svn:special + + * + +""" + class RegexTests(unittest.TestCase): def test_empty_file_re(self): matches = fetch_command.empty_file_patch_wont_make_re.findall(two_empties) assert sorted(matches) == ['__init__.py', 'bar/__init__.py'] - + def test_any_matches_just_one(self): pat = '''Index: trunk/django/contrib/admin/urls/__init__.py =================================================================== ''' matches = fetch_command.any_file_re.findall(pat) assert len(matches) == 1 - + + def test_special_re(self): + matches = fetch_command.property_special_set_re.findall(special_delta) + assert len(matches) == 1 + def test_any_file_re(self): matches = fetch_command.any_file_re.findall(two_empties) assert sorted(matches) == ['__init__.py', 'bar/__init__.py',