Rev 2197: Make all branch_implementations tests pass. in http://bazaar.launchpad.net/~bzr/bzr/hpss
Robert Collins
robertc at robertcollins.net
Thu Mar 29 08:40:51 BST 2007
At http://bazaar.launchpad.net/~bzr/bzr/hpss
------------------------------------------------------------
revno: 2197
revision-id: robertc at robertcollins.net-20070329073949-t6qt1arpx375mjek
parent: robertc at robertcollins.net-20070329072414-7dh0io231c2tormb
committer: Robert Collins <robertc at robertcollins.net>
branch nick: hpss
timestamp: Thu 2007-03-29 17:39:49 +1000
message:
Make all branch_implementations tests pass.
modified:
bzrlib/tests/branch_implementations/test_push.py test_push.py-20070130153159-fhfap8uoifevg30j-1
=== modified file 'bzrlib/tests/branch_implementations/test_push.py'
--- a/bzrlib/tests/branch_implementations/test_push.py 2007-03-28 22:54:43 +0000
+++ b/bzrlib/tests/branch_implementations/test_push.py 2007-03-29 07:39:49 +0000
@@ -18,12 +18,13 @@
import os
+from bzrlib import bzrdir, errors
from bzrlib.branch import Branch
-from bzrlib import errors
from bzrlib.memorytree import MemoryTree
from bzrlib.remote import RemoteBranch
from bzrlib.revision import NULL_REVISION
from bzrlib.tests.branch_implementations.test_branch import TestCaseWithBranch
+from bzrlib.transport.local import LocalURLServer
class TestPush(TestCaseWithBranch):
@@ -133,7 +134,13 @@
try:
tree = a_branch.bzrdir.create_workingtree()
except errors.NotLocalUrl:
- tree = a_branch.create_checkout('repo/tree', lightweight=True)
+ if self.vfs_transport_factory is LocalURLServer:
+ # the branch is colocated on disk, we cannot create a checkout.
+ # hopefully callers will expect this.
+ local_controldir= bzrdir.BzrDir.open(self.get_vfs_only_url('repo/tree'))
+ tree = local_controldir.create_workingtree()
+ else:
+ tree = a_branch.create_checkout('repo/tree', lightweight=True)
self.build_tree(['repo/tree/a'])
tree.add(['a'])
tree.commit('a')
More information about the bazaar-commits
mailing list