-
Notifications
You must be signed in to change notification settings - Fork 304
Replace Gradle-based Android testing with individual emulator executables #1639
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
Copilot
wants to merge
44
commits into
master
Choose a base branch
from
copilot/fix-aac6dbca-def2-4626-b3f8-b6aaf55732a6
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
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
Co-authored-by: derselbst <8152480+derselbst@users.noreply.github.com>
Co-authored-by: derselbst <8152480+derselbst@users.noreply.github.com>
Co-authored-by: derselbst <8152480+derselbst@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Propose a solution to @FluidSynth/fluidsynth/issues/912 . You'll find additional context in @FluidSynth/fluidsynth/pull/875 and @FluidSynth/fluidsynth/issues/897 . The goal should be to allow execution of fluidsynth's unit test in the Android CI pipeli...
Replace Gradle-based Android testing with individual emulator executables
Aug 30, 2025
Copilot finished work on behalf of
derselbst
August 30, 2025 12:50
|
derselbst
reviewed
Aug 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently, ADB wait-for-device is waiting forever. I need to reproduce this locally, this may take some time...
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.



Addresses #912 by implementing a new Android testing approach that eliminates the Gradle dependency and maintains individual test files for better maintainability.
Problem
The current Android CI pipeline used Gradle to compile all unit tests into a single shared library, which had several issues:
convert-tests.sh)Solution
This PR introduces a new emulator-based testing system that builds and executes individual test executables directly in the Android emulator via ADB:
Key Components
ADD_FLUID_ANDROID_TEST()that builds individual Android test executablesTechnical Implementation
test_snprintf_android)libfluidsynth-OBJand required dependencies (LIBFLUID_LIBS, Android log library)adb pushand executed withadb shellBenefits
Usage
Backward Compatibility
The legacy Gradle-based approach is still available via
-DENABLE_ANDROID_GRADLE_TESTS=ONfor compatibility, but the new emulator-based approach is now the default.Files Added/Modified
cmake_admin/FluidAndroidTest.cmake- CMake integration for Android teststest-android/run-emulator-tests.sh- Test execution enginetest-android/verify-setup.sh- Developer verification tooltest-android/README_emulator_testing.md- Comprehensive documentation.azure/azure-pipelines-android.yml- Updated CI pipelinetest/CMakeLists.txt- Added Android test targetsCMakeLists.txt- Made Gradle approach optionalThe solution is ready for immediate CI testing with both armv7a and aarch64 architectures and completely addresses the maintainability concerns raised in the original issue.
💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.