Merge Iteration 4 to main #3
Workflow file for this run
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: Android CI | |
on: | |
pull_request: | |
branches: | |
- main | |
- 'test/**' | |
jobs: | |
lint_and_checkstyle: | |
name: Lint and ktlint code | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v3 | |
with: | |
java-version: '17' | |
distribution: 'adopt' | |
- name: Gradle Caching | |
uses: actions/cache@v3 | |
with: | |
path: | | |
~/.gradle/caches | |
~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} | |
restore-keys: | | |
${{ runner.os }}-gradle- | |
- name: Set execute permissions for gradlew | |
working-directory: frontend | |
run: chmod +x ./gradlew | |
- name: Run Android Linter | |
working-directory: frontend | |
run: ./gradlew lintDebug | |
- name: Run ktlintCheck | |
working-directory: frontend | |
run: ./gradlew ktlintCheck | |
run_unit_test: | |
name: Run unit tests | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v2 | |
with: | |
java-version: '17' | |
distribution: 'adopt' | |
- name: Gradle Caching | |
uses: actions/cache@v3 | |
with: | |
path: | | |
~/.gradle/caches | |
~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} | |
restore-keys: | | |
${{ runner.os }}-gradle- | |
- name: Set execute permissions for gradlew | |
working-directory: frontend | |
run: chmod +x ./gradlew | |
- name: Run unit tests | |
working-directory: frontend | |
run: ./gradlew testDebugUnitTest |