Skip to content

Commit

Permalink
add command for install sdk and create AVD into yml file for Instrume…
Browse files Browse the repository at this point in the history
…nted Tests
  • Loading branch information
Mansi-mParticle committed May 2, 2024
1 parent 8adbf09 commit 172bfdc
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,20 @@ jobs:
run: adb devices
- name: Restart ADB server
run: adb kill-server && adb start-server
- name: Install Android SDK
uses: android-actions/setup-android@v2
with:
sdk-platform: '29' # Adjust the SDK platform version as needed
- name: Create and start emulator
run: |
sdkmanager "system-images;android-29;google_apis;x86_64" --sdk_root=$ANDROID_SDK_ROOT --channel=0
echo "no" | avdmanager --verbose create avd --name test --package "system-images;android-29;google_apis;x86_64" --force
emulator -avd test -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none &
- name: create AVD and generate snapshot for caching
if: steps.avd-cache.outputs.cache-hit != 'true'
uses: reactivecircus/android-emulator-runner@d94c3fbe4fe6a29e4a5ba47c12fb47677c73656b #v2.28.0
with:
api-level: 33
api-level: 29
target: default
arch: x86_64
force-avd-creation: false
Expand All @@ -51,7 +60,7 @@ jobs:
- name: "Run Instrumented Tests"
uses: reactivecircus/android-emulator-runner@d94c3fbe4fe6a29e4a5ba47c12fb47677c73656b #v2.28.0
with:
api-level: 33
api-level: 29
target: default
arch: x86_64
force-avd-creation: false
Expand Down

0 comments on commit 172bfdc

Please sign in to comment.