Rev 5812: Fix pqm failure by requiring the right version of testtools :-/ in file:///home/vila/src/bzr/experimental/config/
Vincent Ladeuil
v.ladeuil+lp at free.fr
Thu Jun 16 18:57:30 UTC 2011
At file:///home/vila/src/bzr/experimental/config/
------------------------------------------------------------
revno: 5812
revision-id: v.ladeuil+lp at free.fr-20110616185729-lh1lkng1yunkn1vk
parent: v.ladeuil+lp at free.fr-20110616141513-mypr0176ur3dpp1l
committer: Vincent Ladeuil <v.ladeuil+lp at free.fr>
branch nick: selftest-config-stats
timestamp: Thu 2011-06-16 20:57:29 +0200
message:
Fix pqm failure by requiring the right version of testtools :-/
-------------- next part --------------
=== modified file 'bzrlib/tests/__init__.py'
--- a/bzrlib/tests/__init__.py 2011-06-16 10:10:54 +0000
+++ b/bzrlib/tests/__init__.py 2011-06-16 18:57:29 +0000
@@ -990,7 +990,7 @@
self.overrideAttr(config, '_expand_default_value', None)
self._log_files = set()
# Each key in the ``_counters`` dict holds a value for a different
- # counter. When the test ends, subunit addDetail() should be used to
+ # counter. When the test ends, testools addDetail() should be used to
# output the counter values. This happens in install_counter_hook().
self._counters = {}
if 'config_stats' in selftest_debug_flags:
@@ -3560,8 +3560,8 @@
# with proper exclusion rules.
# -Ethreads Will display thread ident at creation/join time to
# help track thread leaks
-# -Econfig_stats Will collect statistics using the subunit addDetail
-# API
+
+# -Econfig_stats Will collect statistics using addDetail
selftest_debug_flags = set()
=== modified file 'bzrlib/tests/features.py'
--- a/bzrlib/tests/features.py 2011-03-14 12:43:19 +0000
+++ b/bzrlib/tests/features.py 2011-06-16 18:57:29 +0000
@@ -49,6 +49,7 @@
pywintypes = tests.ModuleAvailableFeature('pywintypes')
sphinx = tests.ModuleAvailableFeature('sphinx')
subunit = tests.ModuleAvailableFeature('subunit')
+testtools = tests.ModuleAvailableFeature('testtools')
class _BackslashDirSeparatorFeature(tests.Feature):
=== modified file 'bzrlib/tests/test_selftest.py'
--- a/bzrlib/tests/test_selftest.py 2011-06-16 14:15:13 +0000
+++ b/bzrlib/tests/test_selftest.py 2011-06-16 18:57:29 +0000
@@ -3597,4 +3597,8 @@
self.assertHookCalls(0, 'no_hook')
def test_run_hook_once(self):
+ tt = features.testtools
+ if tt.module.__version__ < (0, 9, 8):
+ raise tests.TestSkipped('testtools-0.9.8 required for addDetail')
+ self.debug()
self.assertHookCalls(1, 'run_hook_once')
More information about the bazaar-commits
mailing list