[test] Add audio worklet parameter tests (and tidy other interactive tests)#23659
Merged
sbc100 merged 5 commits intoemscripten-core:mainfrom Feb 21, 2025
Merged
[test] Add audio worklet parameter tests (and tidy other interactive tests)#23659sbc100 merged 5 commits intoemscripten-core:mainfrom
sbc100 merged 5 commits intoemscripten-core:mainfrom
Conversation
cwoffenden
added a commit
to cwoffenden/emscripten
that referenced
this pull request
Feb 12, 2025
This was referenced Feb 12, 2025
a041945 to
0f5e291
Compare
sbc100
reviewed
Feb 20, 2025
sbc100
reviewed
Feb 20, 2025
Collaborator
sbc100
left a comment
There was a problem hiding this comment.
lgtm in general, thanks for continuing to work on this.
sbc100
reviewed
Feb 20, 2025
Collaborator
Author
This was actually a fun one to write! |
sbc100
reviewed
Feb 20, 2025
Collaborator
Author
|
All review suggestions done:
|
This mostly adds an Audio Worklet parameter test, but also tidies a little the related tests and shared code.
0588d01 to
a55981e
Compare
sbc100
pushed a commit
that referenced
this pull request
Feb 20, 2025
All the audio tests in `test_browser.py` (except the mixer) were updated now the CI has audio, specifically: - Tests that require audio were flagged as so (tests that don't are documented) - Tests that currently fail for 2GB and wasm64 were flagged (only tests that play audio fail) - All tests were migrated to `btest_exit()` as previously discussed - (Tests moved `printf` calls to Emscripten's API and not stdio) - All tests were run manually and the audio output verified - All tests were run with `emscripten_force_exit` returning non-zero to verify they failed - All of this was also verified that they're running on a Debian VM without audio to manually check the console for `"Test success"` and other outputs for tests without `requires_sound_hardware` The mixer/AW struct test is a standalone PR in #23659. Fixes: #23131
sbc100
reviewed
Feb 21, 2025
| } | ||
|
|
||
| // This implementation has no custom start-up requirements | ||
| EmscriptenStartWebAudioWorkletCallback getStartCallback(void) { |
Collaborator
There was a problem hiding this comment.
Why does this need to be a function that returns a function? Why not just declare a function called startCallback?
Collaborator
Author
There was a problem hiding this comment.
It was because most tests return and use this default function in the shared code:
Whereas one needed a custom implementation, so this was the cleanest way to keep most of the code shared.
Collaborator
Author
There was a problem hiding this comment.
(Cleanest way and still keeping it C)
sbc100
approved these changes
Feb 21, 2025
sbc100
added a commit
to sbc100/emscripten
that referenced
this pull request
Apr 28, 2025
I first noticed a type in audioworklet_params_mixing.c from emscripten-core#23659 then found several other tests with the same issue. Nasty. Not sure what to do about the test_sdl_set_clip_rect assertions which don't seem to be valid (i.e. they fail with the typo fixed).
sbc100
added a commit
to sbc100/emscripten
that referenced
this pull request
Apr 28, 2025
I first noticed a type in audioworklet_params_mixing.c from emscripten-core#23659 then found several other tests with the same issue. Nasty. Not sure what to do about the test_sdl_set_clip_rect assertions which don't seem to be valid (i.e. they fail with the typo fixed).
sbc100
added a commit
to sbc100/emscripten
that referenced
this pull request
Apr 28, 2025
I first noticed a type in audioworklet_params_mixing.c from emscripten-core#23659 then found several other tests with the same issue. Nasty. Not sure what to do about the test_sdl_set_clip_rect assertions which don't seem to be valid (i.e. they fail with the typo fixed).
sbc100
added a commit
to sbc100/emscripten
that referenced
this pull request
Apr 28, 2025
I first noticed a type in audioworklet_params_mixing.c from emscripten-core#23659 then found several other tests with the same issue. Nasty. Not sure what to do about the test_sdl_set_clip_rect assertions which don't seem to be valid (i.e. they fail with the typo fixed).
sbc100
added a commit
to sbc100/emscripten
that referenced
this pull request
Apr 28, 2025
I first noticed a type in audioworklet_params_mixing.c from emscripten-core#23659 then found several other tests with the same issue. Nasty. Not sure what to do about the test_sdl_set_clip_rect assertions which don't seem to be valid (i.e. they fail with the typo fixed).
sbc100
added a commit
that referenced
this pull request
Apr 28, 2025
I first noticed a type in audioworklet_params_mixing.c from #23659 then found several other tests with the same issue. Nasty. Not sure what to do about the test_sdl_set_clip_rect assertions which don't seem to be valid (i.e. they fail with the typo fixed).
sbc100
pushed a commit
that referenced
this pull request
Aug 5, 2025
This pulls the changes out of #23508 to add just the `MEMORY64` support. The already merged interactive tests (from #23659) can be run with: ``` test/runner.py interactive_2gb.test_audio_worklet_params_mixing test/runner.py interactive64_4gb.test_audio_worklet_params_mixing ``` The browser tests with wasm64 have been re-enabled. Note: the intention is to add the performance improvements (from last October) once this is merged (which are still relevant and produce the same improvements).
inolen
pushed a commit
to inolen/emscripten
that referenced
this pull request
Feb 13, 2026
…ipten-core#24732) This pulls the changes out of emscripten-core#23508 to add just the `MEMORY64` support. The already merged interactive tests (from emscripten-core#23659) can be run with: ``` test/runner.py interactive_2gb.test_audio_worklet_params_mixing test/runner.py interactive64_4gb.test_audio_worklet_params_mixing ``` The browser tests with wasm64 have been re-enabled. Note: the intention is to add the performance improvements (from last October) once this is merged (which are still relevant and produce the same improvements).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is splits out the test changes from #23508 adding an interactive parameter test:
This test is also added to the browser tests now #23665 has merged, offering a single test that touches all the various structs and their offsets. When run as part of the
browsertests it plays for 1 second, for interactive without theTEST_AND_EXITmacro it will play continuously.It also tidies a little the shared code (and related tests) in the process. Interactive tests had
_2gband_4gboptions added (which will fail until #23508 lands, but they're not part of the CI). All features of these tests as interactive now work fully on Chrome, Firefox and Safari (Safari has issues with looping, but it doesn't affect the spirit of the test).