'bzr switch' opens too many branches too many times
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Bazaar |
Confirmed
|
Low
|
Unassigned | ||
Breezy |
Triaged
|
Low
|
Unassigned |
Bug Description
I just wrote an effort test for 'bzr switch --create-branch' to make sure we didn't open master branch multiple times.
It turns out that we open things *way* too much. Without my fix, we open the checkout branch 10 times, master branch 2 times, and the target branch 3 times.
def test_switch_
master = self.make_
# Note: not a lightweight checkout
checkout = master.
opened = []
def open_hook(branch):
# Just append the final directory of the branch
b = ['checkout',
'checkout',
'checkout',
'checkout',
'checkout',
'checkout',
'feature',
'master',
'feature',
'checkout',
'checkout',
'checkout',
'master',
'feature',
'checkout']
In theory, we should only open each branch one time. This is capturing Branch.__init__ calls. (via the Branch.open hook).
tags: | added: check-for-breezy |
tags: | removed: check-for-breezy |
Changed in brz: | |
status: | New → Triaged |
importance: | Undecided → Low |