Merge lp:~jelmer/brz/rename-to-empty-dir into lp:brz

Proposed by Jelmer Vernooij
Status: Merged
Approved by: Jelmer Vernooij
Approved revision: no longer in the source branch.
Merge reported by: The Breezy Bot
Merged at revision: not available
Proposed branch: lp:~jelmer/brz/rename-to-empty-dir
Merge into: lp:brz
Diff against target: 21 lines (+7/-4)
1 file modified
breezy/tests/per_workingtree/test_move.py (+7/-4)
To merge this branch: bzr merge lp:~jelmer/brz/rename-to-empty-dir
Reviewer Review Type Date Requested Status
Martin Packman Approve
Review via email: mp+341281@code.launchpad.net

Commit message

Fix one of the rename tests for trees that don't support empty versioned directories.

Description of the change

Fix one of the rename tests for trees that don't support empty versioned directories.

To post a comment you must log in.
Revision history for this message
Martin Packman (gz) wrote :

Okay, see one inline comment.

review: Approve
Revision history for this message
Martin Packman (gz) wrote :

There's an argument that the bzr case should autoversion dirs that `brz mv` puts files under, which would reunify the cases.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'breezy/tests/per_workingtree/test_move.py'
2--- breezy/tests/per_workingtree/test_move.py 2018-02-26 13:36:15 +0000
3+++ breezy/tests/per_workingtree/test_move.py 2018-03-11 00:50:13 +0000
4@@ -608,10 +608,13 @@
5 tree = self.make_branch_and_tree(".")
6 self.build_tree(["a", u"\xA7/"])
7 tree.add(["a"])
8- e = self.assertRaises(errors.BzrMoveFailedError,
9- tree.move, ["a"], u"\xA7")
10- self.assertIsInstance(e.extra, errors.NotVersionedError)
11- self.assertEqual(e.extra.path, u"\xA7")
12+ if tree.has_versioned_directories():
13+ e = self.assertRaises(errors.BzrMoveFailedError,
14+ tree.move, ["a"], u"\xA7")
15+ self.assertIsInstance(e.extra, errors.NotVersionedError)
16+ self.assertEqual(e.extra.path, u"\xA7")
17+ else:
18+ tree.move(["a"], u"\xA7")
19
20 def test_move_unversioned_non_ascii(self):
21 """Check error when moving an unversioned non-ascii file"""

Subscribers

People subscribed via source and target branches