diff options
author | Alon Zakai <alonzakai@gmail.com> | 2013-02-27 19:23:15 -0500 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2013-02-27 19:23:15 -0500 |
commit | 42da4e19f9d72026be6642c8b54f646c6d828dde (patch) | |
tree | fb85330fbffaaa5f904ef6993ac5cdd03ca86368 /tests/runner.py | |
parent | 85b862ac83b28519b572777b849f0011dd437ec1 (diff) |
FORCE_GL_EMULATION option
Diffstat (limited to 'tests/runner.py')
-rwxr-xr-x | tests/runner.py | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/runner.py b/tests/runner.py index d3bdaaac..50568762 100755 --- a/tests/runner.py +++ b/tests/runner.py @@ -10625,10 +10625,14 @@ elif 'browser' in str(sys.argv): self.run_browser('something.html', 'You should see animating gears.', '/report_result?0') def test_glgears_animation(self): - Popen([PYTHON, EMCC, path_from_root('tests', 'hello_world_gles.c'), '-o', 'something.html', - '-DHAVE_BUILTIN_SINCOS', '-s', 'GL_TESTING=1', - '--shell-file', path_from_root('tests', 'hello_world_gles_shell.html')]).communicate() - self.run_browser('something.html', 'You should see animating gears.', '/report_gl_result?true') + for emulation in [0, 1]: + print emulation + Popen([PYTHON, EMCC, path_from_root('tests', 'hello_world_gles.c'), '-o', 'something.html', + '-DHAVE_BUILTIN_SINCOS', '-s', 'GL_TESTING=1', + '--shell-file', path_from_root('tests', 'hello_world_gles_shell.html')] + + (['-s', 'FORCE_GL_EMULATION=1'] if emulation else [])).communicate() + self.run_browser('something.html', 'You should see animating gears.', '/report_gl_result?true') + assert ('var GLEmulation' in open(self.in_dir('something.html')).read()) == emulation, "emulation code should be added when asked for" def test_glgears_bad(self): # Make sure that OpenGL ES is not available if typed arrays are not used |