Merge lp:~jelmer/brz/python3-unversion into lp:brz

Proposed by Jelmer Vernooij on 2018-08-14
Status: Merged
Approved by: Jelmer Vernooij on 2018-08-20
Approved revision: 7068
Merge reported by: The Breezy Bot
Merged at revision: not available
Proposed branch: lp:~jelmer/brz/python3-unversion
Merge into: lp:brz
Prerequisite: lp:~jelmer/brz/python-bundle
Diff against target: 81 lines (+20/-4)
2 files modified
breezy/bzr/workingtree_4.py (+4/-4)
python3.passing (+16/-0)
To merge this branch: bzr merge lp:~jelmer/brz/python3-unversion
Reviewer Review Type Date Requested Status
Martin Packman 2018-08-14 Approve on 2018-08-20
Review via email: mp+353131@code.launchpad.net

Commit message

Fix some unversion tests on Python 3.

Description of the change

Fix some unversion tests on Python 3.

(another ~17 tests)

To post a comment you must log in.
Martin Packman (gz) wrote :

Thanks!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'breezy/bzr/workingtree_4.py'
2--- breezy/bzr/workingtree_4.py 2018-08-05 21:31:40 +0000
3+++ breezy/bzr/workingtree_4.py 2018-08-14 22:32:34 +0000
4@@ -1233,7 +1233,7 @@
5 # walk the state marking unversioned things as absent.
6 # if there are any un-unversioned ids at the end, raise
7 for key, details in state._dirblocks[0][1]:
8- if (details[0][0] not in ('a', 'r') and # absent or relocated
9+ if (details[0][0] not in (b'a', b'r') and # absent or relocated
10 key[2] in ids_to_unversion):
11 # I haven't written the code to unversion / yet - it should be
12 # supported.
13@@ -1261,7 +1261,7 @@
14 entry_index = 0
15 while entry_index < len(block[1]):
16 entry = block[1][entry_index]
17- if entry[1][0][0] in 'ar':
18+ if entry[1][0][0] in (b'a', b'r'):
19 # don't remove absent or renamed entries
20 entry_index += 1
21 else:
22@@ -1277,13 +1277,13 @@
23 entry_index = 0
24 while entry_index < len(block[1]):
25 entry = block[1][entry_index]
26- if (entry[1][0][0] in ('a', 'r') or # absent, relocated
27+ if (entry[1][0][0] in (b'a', b'r') or # absent, relocated
28 # ^ some parent row.
29 entry[0][2] not in ids_to_unversion):
30 # ^ not an id to unversion
31 entry_index += 1
32 continue
33- if entry[1][0][0] == 'd':
34+ if entry[1][0][0] == b'd':
35 paths_to_unversion.add(pathjoin(entry[0][0], entry[0][1]))
36 if not state._make_absent(entry):
37 entry_index += 1
38
39=== modified file 'python3.passing'
40--- python3.passing 2018-08-08 02:10:06 +0000
41+++ python3.passing 2018-08-14 22:32:34 +0000
42@@ -21418,6 +21418,10 @@
43 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_after_conflicted_merge(GitWorkingTreeFormat)
44 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_after_conflicted_merge(WorkingTreeFormat2)
45 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_after_conflicted_merge(WorkingTreeFormat3)
46+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_after_conflicted_merge(WorkingTreeFormat4)
47+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_after_conflicted_merge(WorkingTreeFormat5)
48+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_after_conflicted_merge(WorkingTreeFormat6)
49+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_after_conflicted_merge(WorkingTreeFormat6,remote)
50 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_missing_file(GitWorkingTreeFormat)
51 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_missing_file(WorkingTreeFormat2)
52 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_missing_file(WorkingTreeFormat3)
53@@ -21428,6 +21432,10 @@
54 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_parent_and_child_renamed_bug_187207(GitWorkingTreeFormat)
55 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_parent_and_child_renamed_bug_187207(WorkingTreeFormat2)
56 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_parent_and_child_renamed_bug_187207(WorkingTreeFormat3)
57+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_parent_and_child_renamed_bug_187207(WorkingTreeFormat4)
58+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_parent_and_child_renamed_bug_187207(WorkingTreeFormat5)
59+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_parent_and_child_renamed_bug_187207(WorkingTreeFormat6)
60+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_parent_and_child_renamed_bug_187207(WorkingTreeFormat6,remote)
61 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_renamed(GitWorkingTreeFormat)
62 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_renamed(WorkingTreeFormat2)
63 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_renamed(WorkingTreeFormat3)
64@@ -21452,9 +21460,17 @@
65 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree_and_children(GitWorkingTreeFormat)
66 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree_and_children(WorkingTreeFormat2)
67 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree_and_children(WorkingTreeFormat3)
68+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree_and_children(WorkingTreeFormat4)
69+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree_and_children(WorkingTreeFormat5)
70+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree_and_children(WorkingTreeFormat6)
71+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree_and_children(WorkingTreeFormat6,remote)
72 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree(GitWorkingTreeFormat)
73 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree(WorkingTreeFormat2)
74 breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree(WorkingTreeFormat3)
75+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree(WorkingTreeFormat4)
76+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree(WorkingTreeFormat5)
77+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree(WorkingTreeFormat6)
78+breezy.tests.per_workingtree.test_unversion.TestUnversion.test_unversion_subtree(WorkingTreeFormat6,remote)
79 breezy.tests.per_workingtree.test_views.TestTreeViews.test_check_path_in_view(GitWorkingTreeFormat)
80 breezy.tests.per_workingtree.test_views.TestTreeViews.test_check_path_in_view(WorkingTreeFormat2)
81 breezy.tests.per_workingtree.test_views.TestTreeViews.test_check_path_in_view(WorkingTreeFormat3)

Subscribers

People subscribed via source and target branches