Rev 168: Fix loading of plugins for test suite. in file:///home/jelmer/bzr/pqm/

Jelmer Vernooij jelmer at samba.org
Mon May 21 02:12:28 BST 2007


At file:///home/jelmer/bzr/pqm/

------------------------------------------------------------
revno: 168
revision-id: jelmer at samba.org-20070521010846-h1ajsyewfvizu2kj
parent: jelmer at samba.org-20070521010047-cuk21x5kazzwcyqf
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: pqm
timestamp: Mon 2007-05-21 02:08:46 +0100
message:
  Fix loading of plugins for test suite.
modified:
  pqm/__init__.py                i_dc99ede3-0c64-434d-ac84-305c06455a8d
  pqm/tests/test_pqm.py          x_Robert_Collins_<robert.collins at canonical.com>_Thu_Aug__4_22:52:41_2005_804.0
=== modified file 'pqm/__init__.py'
--- a/pqm/__init__.py	2007-05-20 23:27:46 +0000
+++ b/pqm/__init__.py	2007-05-21 01:08:46 +0000
@@ -1351,13 +1351,12 @@
 
 
 class Bazaar2Handler(VCSHandler):
-
     def __init__(self):
         try:
             import bzrlib
+            bzrlib.plugin.load_plugins()
         except ImportError:
-            return False
-        bzrlib.plugin.load_plugins()
+            pass
 
     def branch_exists(self, sender, branchspec):
         try:

=== modified file 'pqm/tests/test_pqm.py'
--- a/pqm/tests/test_pqm.py	2007-05-20 23:27:46 +0000
+++ b/pqm/tests/test_pqm.py	2007-05-21 01:08:46 +0000
@@ -394,6 +394,8 @@
     def setUp(self):
         from bzrlib.add import smart_add_tree
         from bzrlib.bzrdir import BzrDir
+        from bzrlib.plugin import load_plugins
+        load_plugins()
         tree = BzrDir.create_standalone_workingtree("bzrbranch")
         smart_add_tree(tree, ["bzrbranch"])
         tree.commit("start branch.", verbose=False)
@@ -448,6 +450,8 @@
     def setUp(self):
         from bzrlib.add import smart_add_tree
         from bzrlib.bzrdir import BzrDir
+        from bzrlib.plugin import load_plugins
+        load_plugins()
         tree = BzrDir.create_standalone_workingtree("bzrbranch")
         smart_add_tree(tree, ["bzrbranch"])
         tree.commit("start branch.", verbose=False)




More information about the bazaar-commits mailing list