问题
I have a app released but im receiving some bug from specify Android version - 5.0.2
How can I emulate specific Android version? Api 21 represents versions 5 / 5.0.1 / 5.0.2, but i need to specifically test version 5.0.2.
On Android Emulator i don't have the option for this version, neither on Genymotion. Any ideas?
Edit: Android sdk manager only has versions 5.0.1 and 5.1.1, but not 5.0.2.
回答1:
I just figured it out !!
Let me put here the steps for everyone who is having the same problem (this solution works for different version you might need):
- download the image you want to run from: Factory Images for Nexus Devices
- Create an emulator using Android Studio with the version you need (for my case 5.0.1)
- Open the folder .android/avd/MyEmulatorName/ and paste the
.img
file downloaded in point 1 - Start emulator from command line or from Android Studio
- Once the emulator fully starts you can check the Android version, it should corresponde to the image you downloaded from 1).
This link was my guideline although some steps didn't work for me, like creating the emulator through console.
来源:https://stackoverflow.com/questions/34990149/emulate-specific-android-version