[telepathy-gabble/master] Skip test-debug.py if debugging is disabled

Will Thompson will.thompson at collabora.co.uk
Fri Jun 19 06:17:06 PDT 2009


---
 tests/twisted/Makefile.am   |    5 +++++
 tests/twisted/test-debug.py |    5 +++++
 2 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/tests/twisted/Makefile.am b/tests/twisted/Makefile.am
index 9e7b0d8..b041ea8 100644
--- a/tests/twisted/Makefile.am
+++ b/tests/twisted/Makefile.am
@@ -158,6 +158,11 @@ check-twisted:
 
 config.py: Makefile
 	echo "PACKAGE_STRING = \"$(PACKAGE_STRING)\"" > config.py
+	if test -n ''$(ENABLE_DEBUG); then \
+		echo "DEBUGGING = True" >> config.py; \
+	else \
+		echo "DEBUGGING = False" >> config.py; \
+	fi
 
 BUILT_SOURCES = config.py
 
diff --git a/tests/twisted/test-debug.py b/tests/twisted/test-debug.py
index 60b201c..1cd64b0 100644
--- a/tests/twisted/test-debug.py
+++ b/tests/twisted/test-debug.py
@@ -7,6 +7,11 @@ import dbus
 
 from gabbletest import exec_test
 import constants as cs
+from config import DEBUGGING
+
+if not DEBUGGING:
+    print " --   Not testing debugger, built with --disable-debug"
+    raise SystemExit(77)
 
 path = '/org/freedesktop/Telepathy/debug'
 iface = 'org.freedesktop.Telepathy.Debug.DRAFT'
-- 
1.5.6.5




More information about the telepathy-commits mailing list