Merge lp:~jelmer/loggerhead/allow-missing-tests into lp:loggerhead

Proposed by Jelmer Vernooij
Status: Merged
Approved by: Colin Watson
Approved revision: 540
Merge reported by: Otto Co-Pilot
Merged at revision: 541
Proposed branch: lp:~jelmer/loggerhead/allow-missing-tests
Merge into: lp:loggerhead
Diff against target: 15 lines (+5/-2)
1 file modified
__init__.py (+5/-2)
To merge this branch: bzr merge lp:~jelmer/loggerhead/allow-missing-tests
Reviewer Review Type Date Requested Status
Colin Watson (community) Approve
Review via email: mp+430033@code.launchpad.net

Commit message

When tests are not installed, don't register them.

Description of the change

When tests are not installed, don't register them.

To post a comment you must log in.
Revision history for this message
Colin Watson (cjwatson) :
review: Approve
Revision history for this message
Otto Co-Pilot (otto-copilot) wrote :
Revision history for this message
Otto Co-Pilot (otto-copilot) wrote :

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file '__init__.py'
2--- __init__.py 2022-08-08 17:26:06 +0000
3+++ __init__.py 2022-09-16 15:46:19 +0000
4@@ -121,6 +121,9 @@
5 try:
6 from .loggerhead.tests import test_suite
7 except ImportError:
8- from loggerhead.tests import test_suite
9- basic_tests.addTest(test_suite())
10+ from breezy.trace import mutter
11+ mutter(
12+ 'loggerhead tests not installed, not registering tests')
13+ else:
14+ basic_tests.addTest(test_suite())
15 return basic_tests

Subscribers

People subscribed via source and target branches