[PATCH] test suite: saver check if bzr is installed

Simon Heimberg simohe at besonet.ch
Wed Feb 11 08:27:20 CST 2009


On my debian system there is an (automatic generated) empty __init.py__. Probably because of a module in a subdirectory of bzrlib. Several tests fail because of this.

# HG changeset patch
# User Simon Heimberg <simohe at besonet.ch>
# Date 1234097164 -3600
# Node ID b4b0f40036a389b133e9bc0076aa7662639d5ad9
# Parent  9294c0158c42ce8f8dd884e214386a29d91d6ca4
test suite: saver check if bzr is installed

Test if bzrlib.__doc__ is not empty. Ignores an empty lib.

diff -r 9294c0158c42 -r b4b0f40036a3 tests/hghave
--- a/tests/hghave	Tue Feb 10 13:57:34 2009 +0800
+++ b/tests/hghave	Sun Feb 08 13:46:04 2009 +0100
@@ -27,7 +27,7 @@
 def has_bzr():
     try:
         import bzrlib
-        return True
+        return bzrlib.__doc__ != None
     except ImportError:
         return False
 



More information about the Mercurial-devel mailing list