Rev 2157: Fix test_upgrade_preserves_signatures; it incorrectly assumed that upgrade(wt, ...) would necessarily affect the repository. in sftp://bazaar.launchpad.net/%7Ebzr/bzr/hpss/
Andrew Bennetts
andrew.bennetts at canonical.com
Tue Mar 6 05:37:56 GMT 2007
At sftp://bazaar.launchpad.net/%7Ebzr/bzr/hpss/
------------------------------------------------------------
revno: 2157
revision-id: andrew.bennetts at canonical.com-20070306053139-9rntcbp5gi9008o9
parent: andrew.bennetts at canonical.com-20070305080113-hhmi12uzn1616n2u
committer: Andrew Bennetts <andrew.bennetts at canonical.com>
branch nick: hpss
timestamp: Tue 2007-03-06 16:31:39 +1100
message:
Fix test_upgrade_preserves_signatures; it incorrectly assumed that upgrade(wt, ...) would necessarily affect the repository.
modified:
bzrlib/tests/repository_implementations/test_repository.py test_repository.py-20060131092128-ad07f494f5c9d26c
=== modified file 'bzrlib/tests/repository_implementations/test_repository.py'
--- a/bzrlib/tests/repository_implementations/test_repository.py 2007-03-05 05:15:57 +0000
+++ b/bzrlib/tests/repository_implementations/test_repository.py 2007-03-06 05:31:39 +0000
@@ -303,18 +303,18 @@
self.assertTrue(result.open_repository().is_shared())
self.assertFalse(result.open_repository().make_working_trees())
- def XXXtest_upgrade_preserves_signatures(self):
+ def test_upgrade_preserves_signatures(self):
wt = self.make_branch_and_tree('source')
wt.commit('A', allow_pointless=True, rev_id='A')
- wt.branch.repository.sign_revision('A',
- bzrlib.gpg.LoopbackGPGStrategy(None))
- old_signature = wt.branch.repository.get_signature_text('A')
+ repo = wt.branch.repository
+ repo.sign_revision('A', bzrlib.gpg.LoopbackGPGStrategy(None))
+ old_signature = repo.get_signature_text('A')
try:
old_format = bzrdir.BzrDirFormat.get_default_format()
# This gives metadir branches something they can convert to.
# it would be nice to have a 'latest' vs 'default' concept.
format = bzrdir.format_registry.make_bzrdir('experimental-knit2')
- upgrade(wt.basedir, format=format)
+ upgrade(repo.bzrdir.root_transport.base, format=format)
except errors.UpToDateFormat:
# this is in the most current format already.
return
More information about the bazaar-commits
mailing list