Rev 1742: Fix tests. in file:///data/jelmer/bzr-svn/trunk/
Jelmer Vernooij
jelmer at samba.org
Sun Aug 31 20:59:13 BST 2008
At file:///data/jelmer/bzr-svn/trunk/
------------------------------------------------------------
revno: 1742
revision-id: jelmer at samba.org-20080831195908-i0qw03tgk4kglfyf
parent: jelmer at samba.org-20080831190538-8bok96a30hi0f8a5
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: trunk
timestamp: Sun 2008-08-31 21:59:08 +0200
message:
Fix tests.
modified:
branch.py svnbranch.py-20051017135706-11c749eb0dab04a7
tests/mapping3/__init__.py __init__.py-20080831152358-oy04n53cpnh64aj6-1
tests/test_mapping.py test_mapping.py-20080201131338-0zd86eznn4bojtee-1
=== modified file 'branch.py'
--- a/branch.py 2008-08-30 03:08:49 +0000
+++ b/branch.py 2008-08-31 19:59:08 +0000
@@ -18,6 +18,7 @@
from bzrlib import ui, urlutils
from bzrlib.branch import Branch, BranchFormat, BranchCheckResult, PullResult
from bzrlib.bzrdir import BzrDir
+from bzrlib.decorators import needs_write_lock
from bzrlib.errors import (NoSuchFile, DivergedBranches, NoSuchRevision,
NotBranchError, UnstackableBranchFormat)
from bzrlib.revision import is_null, ensure_null
@@ -338,9 +339,10 @@
# on large branches.
return self.generate_revision_id(self.get_revnum())
+ @needs_write_lock
def dpull(self, source, stop_revision=None):
from bzrlib.plugins.svn.commit import dpush
- return dpush(source, self, stop_revision)
+ return dpush(self, source, stop_revision)
def pull(self, source, overwrite=False, stop_revision=None,
_hook_master=None, run_hooks=True, _push_merged=None):
=== modified file 'tests/mapping3/__init__.py'
--- a/tests/mapping3/__init__.py 2008-08-31 19:05:38 +0000
+++ b/tests/mapping3/__init__.py 2008-08-31 19:59:08 +0000
@@ -13,13 +13,11 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-import sha
-
from bzrlib.tests import TestCase
from bzrlib.plugins.svn.mapping3 import BzrSvnMappingv3FileProps
from bzrlib.plugins.svn.mapping3.scheme import NoBranchingScheme
-from bzrlib.plugins.svn.tests.test_mapping import MappingTestAdapter
+from bzrlib.plugins.svn.tests.test_mapping import MappingTestAdapter, sha1
class Mappingv3FilePropTests(MappingTestAdapter, TestCase):
def setUp(self):
=== modified file 'tests/test_mapping.py'
--- a/tests/test_mapping.py 2008-08-31 15:31:04 +0000
+++ b/tests/test_mapping.py 2008-08-31 19:59:08 +0000
@@ -238,8 +238,6 @@
return sha.new(text).hexdigest()
-
-
class Mappingv4TestAdapter(MappingTestAdapter, TestCase):
def setUp(self):
self.mapping = BzrSvnMappingv4()
More information about the bazaar-commits
mailing list