aboutsummaryrefslogtreecommitdiff
path: root/tests/runner.py
diff options
context:
space:
mode:
authorEhsan Akhgari <ehsan.akhgari@gmail.com>2012-06-21 14:45:55 -0400
committerEhsan Akhgari <ehsan.akhgari@gmail.com>2012-06-21 14:45:55 -0400
commit8058ce6b85b60c737f21d215da128282d914eba7 (patch)
treeddfc261f6a2d86caadf1b11bc508255cafc58834 /tests/runner.py
parenta199aa0e1bcf36fe0a717cf74427d2c0de3c16d3 (diff)
Add a test for basic fog support
Diffstat (limited to 'tests/runner.py')
-rwxr-xr-xtests/runner.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/runner.py b/tests/runner.py
index 7c4df494..a9caacac 100755
--- a/tests/runner.py
+++ b/tests/runner.py
@@ -7652,6 +7652,13 @@ elif 'browser' in str(sys.argv):
Popen(['python', EMCC, path_from_root('tests', 'sdl_ogl_p.c'), '-o', 'something.html', '--pre-js', 'reftest.js', '--preload-file', 'screenshot.png']).communicate()
self.run_browser('something.html', 'You should see an image with gray at the top.', '/report_result?0')
+ def test_sdl_fog1(self):
+ # SDL, OpenGL, textures, fog, immediate mode. Closure for more coverage
+ shutil.copyfile(path_from_root('tests', 'screenshot.png'), os.path.join(self.get_dir(), 'screenshot.png'))
+ self.reftest(path_from_root('tests', 'screenshot-fog1.png'))
+ Popen(['python', EMCC, path_from_root('tests', 'sdl_fog1.c'), '-O2', '--minify', '0', '-o', 'something.html', '--pre-js', 'reftest.js', '--preload-file', 'screenshot.png']).communicate()
+ self.run_browser('something.html', 'You should see an image with fog.', '/report_result?0')
+
def test_worker(self):
# Test running in a web worker
output = Popen(['python', EMCC, path_from_root('tests', 'hello_world_worker.cpp'), '-o', 'worker.js'], stdout=PIPE, stderr=PIPE).communicate()