aboutsummaryrefslogtreecommitdiff
path: root/tests/runner.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/runner.py')
-rwxr-xr-xtests/runner.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/tests/runner.py b/tests/runner.py
index e4aba0c9..6cd3a215 100755
--- a/tests/runner.py
+++ b/tests/runner.py
@@ -8805,7 +8805,7 @@ elif 'sanity' in str(sys.argv):
assert (open(CONFIG_FILE).read() == open(path_from_root('settings.py')).read()), 'Settings should be copied from settings.py'
# Second run, with bad EM_CONFIG
- for settings in ['blah', 'LLVM_ROOT="blah"; JS_ENGINES=[]; COMPILER_ENGINE=NODE_JS=SPIDERMONKEY_ENGINE=[]']:
+ for settings in ['blah', 'LLVM_ROOT="blarg"; JS_ENGINES=[]; COMPILER_ENGINE=NODE_JS=SPIDERMONKEY_ENGINE=[]']:
f = open(CONFIG_FILE, 'w')
f.write(settings)
f.close()
@@ -8901,6 +8901,15 @@ elif 'sanity' in str(sys.argv):
self.assertNotContained(SANITY_MESSAGE, output)
self.assertNotContained(SANITY_FAIL_MESSAGE, output)
+ # but with EMCC_DEBUG=1 we should check
+ assert not os.environ.get('EMCC_DEBUG'), 'do not run sanity checks in debug mode!'
+ os.environ['EMCC_DEBUG'] = '1'
+ output = self.check_working(EMCC)
+ self.assertContained(SANITY_MESSAGE, output)
+ del os.environ['EMCC_DEBUG']
+ output = self.check_working(EMCC)
+ self.assertNotContained(SANITY_MESSAGE, output)
+
# But the test runner should
output = self.check_working(commands[1])
self.assertContained(SANITY_MESSAGE, output)