Skip to content

Fix/plural word not recognised #464

Fix/plural word not recognised

Fix/plural word not recognised #464

Workflow file for this run

name: Android CI
on:
pull_request:
branches:
- main
types: [opened, reopened, synchronize]
permissions:
pull-requests: write
contents: read
jobs:
lint:
runs-on: ubuntu-latest
name: Run Ktlint and Detekt
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Prepare App
uses: ./.github/composite/prepareApp
- name: Run Ktlint
run: ./gradlew lintKotlin
- name: Run Detekt
run: ./gradlew detekt
test:
runs-on: ubuntu-latest
name: Run Tests
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Prepare App
uses: ./.github/composite/prepareApp
- name: Run Ktlint
run: ./gradlew test
collect_coverage:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Set up JDK
uses: actions/setup-java@v1
with:
java-version: 17
- name: Grant Execute Permission for Gradle Wrapper
run: chmod +x gradlew
- name: Get Coverage
run: ./gradlew koverReport
- name: Run File-wise Coverage Parser Script
run: python3 scripts/coverage_parser.py
build:
runs-on: ubuntu-latest
name: build app
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Prepare App
uses: ./.github/composite/prepareApp
- name: Build App
run: ./gradlew assembleDebug
- name: Upload Debug APK
uses: actions/upload-artifact@v4
if: success()
with:
name: latest-apk
path: "app/build/outputs/apk/core/debug/app-core-debug.apk"
instrumentation_test:
runs-on: ubuntu-latest
name: Run Android Instrumentation Tests
timeout-minutes: 50
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Prepare App
uses: ./.github/composite/prepareApp
- name: Enable KVM Group Permissions
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: Run UI Tests on Emulator
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: 29
target: google_apis
arch: x86_64
profile: Nexus 6
ram-size: 2048M
heap-size: 512M
disk-size: 6000M
emulator-options: "-no-window -no-audio -no-boot-anim -camera-back none -camera-front none -gpu swiftshader_indirect -no-snapshot -wipe-data -accel on"
disable-animations: true
force-avd-creation: false
script: |
adb wait-for-device
sleep 30
adb shell input keyevent 82
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 shell pm list packages >/dev/null
sleep 10
adb shell getprop sys.boot_completed
./gradlew connectedCoreDebugAndroidTest --stacktrace