restore necessary hashorder fix

This commit is contained in:
Joe Orton 2012-03-12 13:50:34 +00:00
parent 3ee8fd7773
commit cf9cd946d8

View File

@ -18,6 +18,44 @@ Remaining fixes for APR hashorder issues.
self.assertEqual(len(editor.textdeltas), 2) self.assertEqual(len(editor.textdeltas), 2)
def test_retrieve_and_change_rev_prop(self): def test_retrieve_and_change_rev_prop(self):
--- subversion-1.7.4/subversion/bindings/swig/python/tests/trac/versioncontrol/tests/svn_fs.py.hashorder
+++ subversion-1.7.4/subversion/bindings/swig/python/tests/trac/versioncontrol/tests/svn_fs.py
@@ -264,16 +264,25 @@ class SubversionRepositoryTestCase(unitt
def test_diff_dir_different_revs(self):
diffs = self.repos.get_deltas('trunk', 4, 'trunk', 8)
- self._cmp_diff((None, ('trunk/dir1/dir2', 8),
- (Node.DIRECTORY, Changeset.ADD)), diffs.next())
- self._cmp_diff((None, ('trunk/dir1/dir3', 8),
- (Node.DIRECTORY, Changeset.ADD)), diffs.next())
- self._cmp_diff((None, ('trunk/README2.txt', 6),
- (Node.FILE, Changeset.ADD)), diffs.next())
- self._cmp_diff((('trunk/dir2', 4), None,
- (Node.DIRECTORY, Changeset.DELETE)), diffs.next())
- self._cmp_diff((('trunk/dir3', 4), None,
- (Node.DIRECTORY, Changeset.DELETE)), diffs.next())
+ expected = [
+ (None, ('trunk/README2.txt', 6),
+ (Node.FILE, Changeset.ADD)),
+ (None, ('trunk/dir1/dir2', 8),
+ (Node.DIRECTORY, Changeset.ADD)),
+ (None, ('trunk/dir1/dir3', 8),
+ (Node.DIRECTORY, Changeset.ADD)),
+ (('trunk/dir2', 4), None,
+ (Node.DIRECTORY, Changeset.DELETE)),
+ (('trunk/dir3', 4), None,
+ (Node.DIRECTORY, Changeset.DELETE)),
+ ]
+ actual = [diffs.next() for i in range(5)]
+ actual = sorted(actual,
+ key=lambda diff: ((diff[0] or diff[1]).path,
+ (diff[0] or diff[1]).rev))
+ self.assertEqual(len(expected), len(actual))
+ for e,a in zip(expected, actual):
+ self._cmp_diff(e,a)
self.assertRaises(StopIteration, diffs.next)
def test_diff_dir_different_dirs(self):
--- subversion-1.7.4/subversion/bindings/swig/python/tests/wc.py.hashorder --- subversion-1.7.4/subversion/bindings/swig/python/tests/wc.py.hashorder
+++ subversion-1.7.4/subversion/bindings/swig/python/tests/wc.py +++ subversion-1.7.4/subversion/bindings/swig/python/tests/wc.py
@@ -216,8 +216,9 @@ class SubversionWorkingCopyTestCase(unit @@ -216,8 +216,9 @@ class SubversionWorkingCopyTestCase(unit