summaryrefslogtreecommitdiffstats
path: root/testsuite/common.py
diff options
context:
space:
mode:
authorChris St. Pierre <chris.a.st.pierre@gmail.com>2014-10-22 11:02:51 -0500
committerChris St. Pierre <chris.a.st.pierre@gmail.com>2014-10-22 13:11:55 -0500
commit7a4dd4b3436cd85ee46acd07e85e7769f739b87f (patch)
tree7a6d4f1706ec4c40118d722dd2b697d70645e9a6 /testsuite/common.py
parent1a54f2a549b86be5a976d2a43a7985c1265d916a (diff)
downloadbcfg2-7a4dd4b3436cd85ee46acd07e85e7769f739b87f.tar.gz
bcfg2-7a4dd4b3436cd85ee46acd07e85e7769f739b87f.tar.bz2
bcfg2-7a4dd4b3436cd85ee46acd07e85e7769f739b87f.zip
testsuite: better debug capturing for options tests
Diffstat (limited to 'testsuite/common.py')
-rw-r--r--testsuite/common.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/testsuite/common.py b/testsuite/common.py
index 49579d7ef..a86e9c5d9 100644
--- a/testsuite/common.py
+++ b/testsuite/common.py
@@ -38,7 +38,13 @@ def set_setup_default(option, value=None):
if not hasattr(Bcfg2.Options.setup, option):
setattr(Bcfg2.Options.setup, option, value)
+# these two variables do slightly different things for unit tests; the
+# former skips config file reading, while the latter sends option
+# debug logging to stdout so it can be captured. These are separate
+# because we want to enable config file reading in order to test
+# option parsing.
Bcfg2.Options.Parser.unit_test = True
+Bcfg2.Options.Options.unit_test = True
try:
import django.conf