summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonny Lamb <jonny.lamb@collabora.co.uk>2012-05-02 12:15:39 +0100
committerJonny Lamb <jonny.lamb@collabora.co.uk>2012-05-02 12:15:39 +0100
commitad7122d60c70ba106661a0b0ecd58e36420d46d5 (patch)
tree868ac87327578611b7b818dd88fddcc0103b4c76
parent41b053cdcc220687506d8922e129ef759d70fddb (diff)
downloadtelepathy-haze-ad7122d60c70ba106661a0b0ecd58e36420d46d5.tar.gz
twisted tests: add a config module for knowing whether media is enabled
Signed-off-by: Jonny Lamb <jonny.lamb@collabora.co.uk>
-rw-r--r--.gitignore1
-rw-r--r--tests/twisted/Makefile.am15
2 files changed, 15 insertions, 1 deletions
diff --git a/.gitignore b/.gitignore
index 83eea4e..1776590 100644
--- a/.gitignore
+++ b/.gitignore
@@ -34,6 +34,7 @@ tags
/tests/haze-testing.log
/tests/org.freedesktop.Telepathy.ConnectionManager.haze.service
/tests/tmp-session-bus.conf
+/tests/twisted/config.py
/telepathy-haze*.tar.gz*
/telepathy-haze*/
diff --git a/tests/twisted/Makefile.am b/tests/twisted/Makefile.am
index 3f89664..ddf31ae 100644
--- a/tests/twisted/Makefile.am
+++ b/tests/twisted/Makefile.am
@@ -43,4 +43,17 @@ EXTRA_DIST = \
servicetest.py \
ns.py
-CLEANFILES = *.pyc */*.pyc
+if MEDIA_ENABLED
+MEDIA_ENABLED_PYBOOL = True
+else
+MEDIA_ENABLED_PYBOOL = False
+endif
+
+config.py: Makefile
+ $(AM_V_GEN) { \
+ echo "MEDIA_ENABLED = $(MEDIA_ENABLED_PYBOOL)"; \
+ } > $@
+
+BUILT_SOURCES = config.py
+
+CLEANFILES = *.pyc */*.pyc config.py