aboutsummaryrefslogtreecommitdiff
path: root/tests/runner.py
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2012-09-21 10:26:31 -0700
committerAlon Zakai <alonzakai@gmail.com>2012-09-21 10:26:31 -0700
commit42fe18db80384fe9e0f0be7e367e6e8a5e20a1d8 (patch)
tree1b56452394349fb5b3e4f2afdf01c367c176363b /tests/runner.py
parent55f85c0abaa05e88f2450311488fa88236d16146 (diff)
parentb3039131e6df864d05f3492d02169e0434c142d3 (diff)
Merge pull request #570 from ysangkok/for-upstream
don't pass EMCC specific flags on when configuring using clang
Diffstat (limited to 'tests/runner.py')
-rwxr-xr-xtests/runner.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/runner.py b/tests/runner.py
index 090ad3f0..baa9eb5e 100755
--- a/tests/runner.py
+++ b/tests/runner.py
@@ -7674,6 +7674,19 @@ fscanfed: 10 - hello
code = open('a.out.js').read()
assert 'SAFE_HEAP' in code, 'valid -s option had an effect'
+ def test_conftest_s_flag_passing(self):
+ open(os.path.join(self.get_dir(), 'conftest.c'), 'w').write(r'''
+ int main() {
+ return 0;
+ }
+ ''')
+ os.environ["EMMAKEN_JUST_CONFIGURE"] = "1"
+ cmd = ['python', EMCC, '-s', 'ASSERTIONS=1', os.path.join(self.get_dir(), 'conftest.c'), '-o', 'conftest']
+ output = Popen(cmd, stderr=PIPE).communicate()
+ self.assertNotContained('emcc: warning: treating -s as linker option', output[1])
+ assert os.path.exists('conftest')
+ del os.environ["EMMAKEN_JUST_CONFIGURE"]
+
def test_crunch(self):
# crunch should not be run if a .crn exists that is more recent than the .dds
shutil.copyfile(path_from_root('tests', 'ship.dds'), 'ship.dds')