diff options
author | Richard Darst <rkd@zgib.net> | 2009-09-12 03:15:47 (GMT) |
---|---|---|
committer | Richard Darst <rkd@zgib.net> | 2009-09-12 03:15:47 (GMT) |
commit | c90f88964dfb28a4a2cba0b6c68d63d8ce8588ae (patch) | |
tree | 58cce6c287cc138336c6758dea745ee9042d3731 /meeting.py | |
parent | affdec1e4b7849207c7721bc7d6d50298581693b (diff) |
Create ways for tests to disable meetingLocalConfig
- We have the __main__.running_tests that can disable it, for things
running in the same python process.
- We have an environment variable MEETBOT_RUNNING_TESTS for different
python processes.
darcs-hash:20090912031547-82ea9-2eaee7f221b6fc07e42fdd0bb04e4c11c6037154.gz
Diffstat (limited to 'meeting.py')
-rw-r--r-- | meeting.py | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -234,6 +234,10 @@ time.tzset() # load custom local configurations try: + import __main__ + if getattr(__main__, 'running_tests', False): raise ImportError + if 'MEETBOT_RUNNING_TESTS' in os.environ: raise ImportError + import meetingLocalConfig meetingLocalConfig = reload(meetingLocalConfig) if hasattr(meetingLocalConfig, 'Config'): |