Take screenshots and create PR #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Take screenshots and create Pull Request | |
on: | |
workflow_dispatch: | |
jobs: | |
run-tests: | |
runs-on: ubuntu-latest | |
steps: | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: Enable KVM | |
run: | | |
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules | |
sudo udevadm control --reload-rules | |
sudo udevadm trigger --name-match=kvm | |
- name: Setup Python dependencies for the screenshot server | |
run: python -m pip install flask | |
- name: Start screenshot server | |
run: python ./app/src/androidTest/kotlin/org/stypox/dicio/screenshot/screenshot_server.py & | |
- name: Run Android instrumented tests | |
uses: reactivecircus/android-emulator-runner@v2 | |
with: | |
api-level: 34 | |
target: default | |
arch: x86_64 | |
profile: Pixel 3a XL | |
script: ./gradlew connectedCheck -P android.testInstrumentationRunnerArguments.class=org.stypox.dicio.screenshot.ScreenshotTakerTest | |
- name: Print git status | |
run: git status |