android-emulator-container-scripts icon indicating copy to clipboard operation
android-emulator-container-scripts copied to clipboard

Can't disable animations for espresso tests

Open TomBAMU opened this issue 4 years ago • 1 comments

I really enjoy working with the emulator-container-scripts. Though I recently made the experience, there is no possibility to disable the developer settings via adb with an Android M emulator. I tried the following steps.

  • locally started the container(Also reproducable in my kubernetes cluster with nested virtualization)
  • enable developer settings and disable animations via adb. Reboot afterwards to propagate changes
adb shell settings put global development_settings_enabled 1
adb shell settings put global window_animation_scale 0.0
adb shell settings put global transition_animation_scale 0.0
adb shell settings put global animator_duration_scale 0.0
adb reboot
  • Execute my UI-Tests via commandline Result: Tests fail

Emulator: AOSP Image with Android M

After trying this with a stock emulator configured with Android Studio, everything works like a charm

Do I miss a setting anywhere? Are animations working with headless emulators ( "-no-window" ) at all? I'm reaching out since this issue stumped me

TomBAMU avatar Mar 18 '21 08:03 TomBAMU

Could this be performance related? The containers usually launch with software rendering, which might not give enough gpu performance.

pokowaka avatar May 11 '21 15:05 pokowaka