Skip to content

Commit ccdbb65

Browse files
authored
Remove redundant code in test_sdl2_gl_frames_swap. NFC (#22594)
The post_build function here exists solely in order to patch out (remove) the auto running on doRefTest. However the test is already built with `manual_reference=True` which already does this.
1 parent 90bcd35 commit ccdbb65

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

test/test_browser.py

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3063,13 +3063,7 @@ def test_sdl2_canvas_write(self):
30633063

30643064
@requires_graphics_hardware
30653065
def test_sdl2_gl_frames_swap(self):
3066-
def post_build():
3067-
self.post_manual_reftest()
3068-
reftest = read_file('reftest.js')
3069-
reftest2 = reftest.replace("Module['postRun'] = doReftest;", '') # we don't want the very first frame
3070-
assert reftest != reftest2
3071-
create_file('reftest.js', reftest2)
3072-
self.reftest('test_sdl2_gl_frames_swap.c', 'test_sdl2_gl_frames_swap.png', args=['--proxy-to-worker', '-sGL_TESTING', '-sUSE_SDL=2'], manual_reference=True, post_build=post_build)
3066+
self.reftest('test_sdl2_gl_frames_swap.c', 'test_sdl2_gl_frames_swap.png', args=['--proxy-to-worker', '-sGL_TESTING', '-sUSE_SDL=2'], manual_reference=True, post_build=self.post_manual_reftest)
30733067

30743068
@requires_graphics_hardware
30753069
def test_sdl2_ttf(self):

0 commit comments

Comments
 (0)