@@ -55,10 +55,10 @@ def test_sdl2_togglefullscreen(self):
5555 self .btest_exit ('browser/test_sdl_togglefullscreen.c' , args = ['-sUSE_SDL=2' ])
5656
5757 def test_sdl_audio (self ):
58- shutil .copyfile (test_file ('sounds' , ' alarmvictory_1.ogg' ), self .in_dir ('sound.ogg' ))
59- shutil .copyfile (test_file ('sounds' , ' alarmcreatemiltaryfoot_1.wav' ), self .in_dir ('sound2.wav' ))
60- shutil .copyfile (test_file ('sounds' , ' noise.ogg' ), self .in_dir ('noise.ogg' ))
61- shutil .copyfile (test_file ('sounds' , ' the_entertainer.ogg' ), self .in_dir ('the_entertainer.ogg' ))
58+ shutil .copyfile (test_file ('sounds/ alarmvictory_1.ogg' ), self .in_dir ('sound.ogg' ))
59+ shutil .copyfile (test_file ('sounds/ alarmcreatemiltaryfoot_1.wav' ), self .in_dir ('sound2.wav' ))
60+ shutil .copyfile (test_file ('sounds/ noise.ogg' ), self .in_dir ('noise.ogg' ))
61+ shutil .copyfile (test_file ('sounds/ the_entertainer.ogg' ), self .in_dir ('the_entertainer.ogg' ))
6262 create_file ('bad.ogg' , 'I claim to be audio, but am lying' )
6363
6464 # use closure to check for a possible bug with closure minifying away newer Audio() attributes
@@ -78,7 +78,7 @@ def test_sdl_audio(self):
7878 'wasmfs' : (['-sWASMFS' ],),
7979 })
8080 def test_sdl_audio_mix_channels (self , args ):
81- shutil .copyfile (test_file ('sounds' , ' noise.ogg' ), self .in_dir ('sound.ogg' ))
81+ shutil .copyfile (test_file ('sounds/ noise.ogg' ), self .in_dir ('sound.ogg' ))
8282
8383 self .btest_exit ('sdl_audio_mix_channels.c' , args = ['-O2' , '--minify=0' , '--preload-file' , 'sound.ogg' ] + args )
8484
@@ -87,14 +87,14 @@ def test_sdl_audio_mix_channels(self, args):
8787 'wasmfs' : (['-sWASMFS' ],),
8888 })
8989 def test_sdl_audio_mix (self , args ):
90- shutil .copyfile (test_file ('sounds' , ' pluck.ogg' ), self .in_dir ('sound.ogg' ))
91- shutil .copyfile (test_file ('sounds' , ' the_entertainer.ogg' ), self .in_dir ('music.ogg' ))
92- shutil .copyfile (test_file ('sounds' , ' noise.ogg' ), self .in_dir ('noise.ogg' ))
90+ shutil .copyfile (test_file ('sounds/ pluck.ogg' ), self .in_dir ('sound.ogg' ))
91+ shutil .copyfile (test_file ('sounds/ the_entertainer.ogg' ), self .in_dir ('music.ogg' ))
92+ shutil .copyfile (test_file ('sounds/ noise.ogg' ), self .in_dir ('noise.ogg' ))
9393
9494 self .btest_exit ('sdl_audio_mix.c' , args = ['-O2' , '--minify=0' , '--preload-file' , 'sound.ogg' , '--preload-file' , 'music.ogg' , '--preload-file' , 'noise.ogg' ] + args )
9595
9696 def test_sdl_audio_panning (self ):
97- shutil .copyfile (test_file ('sounds' , ' the_entertainer.wav' ), self .in_dir ('the_entertainer.wav' ))
97+ shutil .copyfile (test_file ('sounds/ the_entertainer.wav' ), self .in_dir ('the_entertainer.wav' ))
9898
9999 # use closure to check for a possible bug with closure minifying away newer Audio() attributes
100100 self .btest_exit ('sdl_audio_panning.c' , args = ['-O2' , '--closure=1' , '--minify=0' , '--preload-file' , 'the_entertainer.wav' , '-sEXPORTED_FUNCTIONS=_main,_play' ])
@@ -104,7 +104,7 @@ def test_sdl_audio_beeps(self):
104104 self .btest_exit ('sdl_audio_beep.cpp' , args = ['-O2' , '--closure=1' , '--minify=0' , '-sDISABLE_EXCEPTION_CATCHING=0' , '-o' , 'page.html' ])
105105
106106 def test_sdl2_mixer_wav (self ):
107- shutil .copyfile (test_file ('sounds' , ' the_entertainer.wav' ), 'sound.wav' )
107+ shutil .copyfile (test_file ('sounds/ the_entertainer.wav' ), 'sound.wav' )
108108 self .btest_exit ('browser/test_sdl2_mixer_wav.c' , args = [
109109 '-O2' ,
110110 '-sUSE_SDL=2' ,
@@ -138,47 +138,47 @@ def test_sdl2_audio_beeps(self):
138138 self .btest_exit ('browser/test_sdl2_audio_beep.cpp' , args = ['-O2' , '--closure=1' , '--minify=0' , '-sDISABLE_EXCEPTION_CATCHING=0' , '-sUSE_SDL=2' ])
139139
140140 def test_openal_playback (self ):
141- shutil .copyfile (test_file ('sounds' , ' audio.wav' ), self .in_dir ('audio.wav' ))
141+ shutil .copyfile (test_file ('sounds/ audio.wav' ), self .in_dir ('audio.wav' ))
142142
143143 for args in [[], ['-pthread' , '-sPROXY_TO_PTHREAD' ]]:
144144 self .compile_btest (['-O2' , test_file ('openal_playback.cpp' ), '--preload-file' , 'audio.wav' , '-o' , 'page.html' ] + args )
145145 self .run_browser ('page.html' , '/report_result?1' )
146146
147147 def test_openal_buffers (self ):
148- self .btest ('openal_buffers.c' , '0' , args = ['--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/' ],)
148+ self .btest ('openal_buffers.c' , '0' , args = ['--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/' ],)
149149
150150 def test_openal_buffers_animated_pitch (self ):
151- self .btest ('openal_buffers.c' , '0' , args = ['-DTEST_ANIMATED_PITCH=1' , '--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/' ],)
151+ self .btest ('openal_buffers.c' , '0' , args = ['-DTEST_ANIMATED_PITCH=1' , '--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/' ],)
152152
153153 def test_openal_looped_pitched_playback (self ):
154- self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/audio.wav' ],)
154+ self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/audio.wav' ],)
155155
156156 def test_openal_looped_seek_playback (self ):
157- self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_LOOPED_SEEK_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/audio.wav' ],)
157+ self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_LOOPED_SEEK_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/audio.wav' ],)
158158
159159 def test_openal_animated_looped_pitched_playback (self ):
160- self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ANIMATED_LOOPED_PITCHED_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/audio.wav' ],)
160+ self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ANIMATED_LOOPED_PITCHED_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/audio.wav' ],)
161161
162162 def test_openal_animated_looped_distance_playback (self ):
163- self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ANIMATED_LOOPED_DISTANCE_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/audio.wav' ],)
163+ self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ANIMATED_LOOPED_DISTANCE_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/audio.wav' ],)
164164
165165 def test_openal_animated_looped_doppler_playback (self ):
166- self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ANIMATED_LOOPED_DOPPLER_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/audio.wav' ],)
166+ self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ANIMATED_LOOPED_DOPPLER_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/audio.wav' ],)
167167
168168 def test_openal_animated_looped_panned_playback (self ):
169- self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ANIMATED_LOOPED_PANNED_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/audio.wav' ],)
169+ self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ANIMATED_LOOPED_PANNED_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/audio.wav' ],)
170170
171171 def test_openal_animated_looped_relative_playback (self ):
172- self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ANIMATED_LOOPED_RELATIVE_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/audio.wav' ],)
172+ self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ANIMATED_LOOPED_RELATIVE_PLAYBACK=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/audio.wav' ],)
173173
174174 def test_openal_al_soft_loop_points (self ):
175- self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_AL_SOFT_LOOP_POINTS=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/audio.wav' ],)
175+ self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_AL_SOFT_LOOP_POINTS=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/audio.wav' ],)
176176
177177 def test_openal_alc_soft_pause_device (self ):
178- self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ALC_SOFT_PAUSE_DEVICE=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/audio.wav' ],)
178+ self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_ALC_SOFT_PAUSE_DEVICE=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/audio.wav' ],)
179179
180180 def test_openal_al_soft_source_spatialize (self ):
181- self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_AL_SOFT_SOURCE_SPATIALIZE=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds' , ' the_entertainer.wav' ) + '@/audio.wav' ],)
181+ self .btest ('openal_playback.cpp' , '1' , args = ['-DTEST_AL_SOFT_SOURCE_SPATIALIZE=1' , '-DTEST_LOOPED_PLAYBACK=1' , '--preload-file' , test_file ('sounds/ the_entertainer.wav' ) + '@/audio.wav' ],)
182182
183183 def test_openal_capture (self ):
184184 self .btest ('openal_capture.c' , expected = '0' )
@@ -191,8 +191,8 @@ def get_freealut_library(self):
191191 return self .get_library (os .path .join ('third_party' , 'freealut' ), os .path .join ('src' , '.libs' , 'libalut.a' ), configure_args = ['--disable-shared' ])
192192
193193 def test_freealut (self ):
194- src = test_file ('third_party' , ' freealut' , 'examples' , 'hello_world.c' )
195- inc = test_file ('third_party' , ' freealut' , 'include' )
194+ src = test_file ('third_party/ freealut' , 'examples' , 'hello_world.c' )
195+ inc = test_file ('third_party/ freealut' , 'include' )
196196 self .compile_btest ([src , '-O2' , '-o' , 'page.html' , '-I' + inc ] + self .get_freealut_library ())
197197 self .run_browser ('page.html' , message = 'You should hear "Hello World!"' )
198198
@@ -228,7 +228,7 @@ def test_threadprofiler(self):
228228 '-DTEST_THREAD_PROFILING=1' ,
229229 '-sPTHREAD_POOL_SIZE=16' ,
230230 '-sINITIAL_MEMORY=64mb' ,
231- '--shell-file' , test_file ('pthread' , ' test_pthread_mandelbrot_shell.html' )]
231+ '--shell-file' , test_file ('pthread/ test_pthread_mandelbrot_shell.html' )]
232232 self .btest_exit ('pthread/test_pthread_mandelbrot.cpp' , args = args )
233233
234234 # Test that event backproxying works.
0 commit comments