Fix AVD tests

This commit is contained in:
topjohnwu 2024-12-23 19:49:21 -08:00 committed by John Wu
parent 5885b8c20d
commit 6707b72260
3 changed files with 10 additions and 1 deletions

View File

@ -218,6 +218,9 @@ yes | "$sdk" --licenses > /dev/null
curl -L $lsposed_url -o out/lsposed.zip
"$sdk" --channel=3 platform-tools emulator
adb kill-server
adb start-server
if [ -n "$1" ]; then
run_test $1 $2
else

View File

@ -27,7 +27,9 @@ setup_env() {
sudo udevadm trigger
sudo usermod -aG kvm,cvdnetwork,render $USER
yes | "$sdk" --licenses > /dev/null
"$sdk" --channel=3 tools platform-tools
"$sdk" --channel=3 platform-tools
adb kill-server
adb start-server
}
download_cf() {

View File

@ -2,6 +2,10 @@ if [ -z $ANDROID_HOME ]; then
export ANDROID_HOME=$ANDROID_SDK_ROOT
fi
# Make sure paths are consistent
export ANDROID_USER_HOME="$HOME/.android"
export ANDROID_EMULATOR_HOME="$ANDROID_USER_HOME"
export ANDROID_AVD_HOME="$ANDROID_EMULATOR_HOME/avd"
export PATH="$PATH:$ANDROID_HOME/platform-tools"
emu="$ANDROID_HOME/emulator/emulator"