diff options
author | Alon Zakai <alonzakai@gmail.com> | 2012-06-13 13:53:13 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2012-06-13 13:53:13 -0700 |
commit | 54e6ad2f8f20c9b72aaa12888568108ba2d20da2 (patch) | |
tree | 7b8f3271250dd04e6e78135200a50401fb787706 /tests/runner.py | |
parent | 52a5e5e9dc2d2ce9a26ba3a9393dbf8bae93787f (diff) | |
parent | aad005f54a21a91b64bc07fe7ede67bd79f4f2d2 (diff) |
Merge pull request #466 from caiiiycuk/SDL_HWPALETTE
Implementation of SDL_Surface with SDL_HWPALETTE flag (8bpp surface)
Diffstat (limited to 'tests/runner.py')
-rwxr-xr-x | tests/runner.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/runner.py b/tests/runner.py index 62306a67..31408b96 100755 --- a/tests/runner.py +++ b/tests/runner.py @@ -7456,6 +7456,19 @@ elif 'browser' in str(sys.argv): Popen(['python', EMCC, os.path.join(self.get_dir(), 'sdl_canvas.c'), '-o', 'page.html']).communicate() self.run_browser('page.html', '', '/report_result?1') + def test_sdl_canvas_palette(self): + open(os.path.join(self.get_dir(), 'sdl_canvas_palette.c'), 'w').write(self.with_report_result(open(path_from_root('tests', 'sdl_canvas_palette.c')).read())) + + Popen(['python', EMCC, os.path.join(self.get_dir(), 'sdl_canvas_palette.c'), '-o', 'page.html']).communicate() + self.run_browser('page.html', '') + + def test_sdl_canvas_palette_2(self): + open(os.path.join(self.get_dir(), 'sdl_canvas_palette_2.c'), 'w').write(self.with_report_result(open(path_from_root('tests', 'sdl_canvas_palette_2.c')).read())) + open(os.path.join(self.get_dir(), 'pre.js'), 'w').write('Module[\'preRun\'] = function() { SDL.defaults.copyOnLock = false }') + + Popen(['python', EMCC, os.path.join(self.get_dir(), 'sdl_canvas_palette_2.c'), '-o', 'page.html', '--pre-js', 'pre.js']).communicate() + self.run_browser('page.html', '') + def test_sdl_key(self): open(os.path.join(self.get_dir(), 'pre.js'), 'w').write(''' Module.postRun = function() { |