android-orb
android-orb copied to clipboard
Latest Orb Does Not Work
Orb version
2.3.0
What happened
Fails to start emulator on docker image due to GPU, no settings on gpu work.
Starting emulator with arguments -gpu swiftshader_indirect
INFO | Android emulator version 32.1.14.0 (build_id 10330179) (CL:N/A)
INFO | Found systemPath /home/circleci/android-sdk/system-images/android-30/google_apis/x86/
INFO | Storing crashdata in: /tmp/android-unknown/emu-crash.db, detection is enabled
INFO | Duplicate loglines will be removed, if you wish to see each indiviudal line launch with the -log-nofilter flag.
WARNING | Please update the emulator to one that supports the feature(s): Vulkan
WARNING | Failed to process .ini file /home/circleci/.android/avd/test.avd/quickbootChoice.ini for reading.
ERROR | x86 emulation currently requires hardware acceleration!
CPU acceleration status: KVM requires a CPU that supports vmx or svm
More info on configuring VM acceleration on Linux:
https://developer.android.com/studio/run/emulator-acceleration#vm-linux
General information on acceleration: https://developer.android.com/studio/run/emulator-acceleration.
Exited with code exit status 1
Using android-machine the emulator looks like it does start and then fails because it can't connect add.
executor:
name: android/android-machine
resource-class: 2xlarge
tag: 2023.07.1
ERROR | Unable to connect to adb daemon on port: 5037
INFO | Revoking microphone permissions for Google App.
INFO | Wait for emulator (pid 3618) 20 seconds to shutdown gracefully before kill;you can set environment variable ANDROID_EMULATOR_WAIT_TIME_BEFORE_KILL(in seconds) to change the default value (20 seconds)
Using an example from https://dev.to/roselinebassey/android-automate-instrumented-and-unit-tests-with-circleci-1igo fails too!
test_ui:
steps:
# Then start the emulator and run the Instrumentation tests!
- run:
name: installing emulator and Running Instrumentation tests
command: |
sdkmanager "platform-tools" "platforms;android-29" "build-tools;30.0.0" "emulator"
sdkmanager "system-images;android-29;google_apis;x86"
echo no | avdmanager create avd -n test-emulator -k "system-images;android-29;google_apis;x86"
emulator -avd test-emulator -noaudio -no-boot-anim -gpu off -no-window &
adb wait-for-device shell 'while [[ -z $(getprop sys.boot_completed) ]]; do sleep 1; done;'
adb shell wm dismiss-keyguard
sleep 1
adb shell settings put global window_animation_scale 0
adb shell settings put global transition_animation_scale 0
adb shell settings put global animator_duration_scale 0
./gradlew connectedAndroidTest
Expected behavior
Emulator should run and tests run
Hi @grndvl1 can you update this issue with a config showing how you used the orb and potentially a link to a failing build?
I'm closing this as there hasn't been any extra information given about it.