Skip to content

Commit

Permalink
use the same cache settings for android tests, update concurrency (ho…
Browse files Browse the repository at this point in the history
…pefully android and kt tests run in parallel again?)
  • Loading branch information
aSemy committed Jul 25, 2022
1 parent b9dbde2 commit 6d810ba
Showing 1 changed file with 14 additions and 10 deletions.
24 changes: 14 additions & 10 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@ on:
pull_request:
branches: [ master ]

# This allows a subsequently queued workflow run to interrupt previous runs
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
group: '${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}'
cancel-in-progress: true

jobs:
Expand All @@ -23,14 +24,12 @@ jobs:
steps:
- uses: actions/checkout@v2

# Cache Gradle dependencies
- name: Setup Gradle Dependencies Cache
uses: actions/cache@v3
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-caches-${{ hashFiles('**/*.gradle', '**/*.gradle.kts') }}

# Cache Gradle Wrapper
- name: Setup Gradle Wrapper Cache
uses: actions/cache@v3
with:
Expand Down Expand Up @@ -59,14 +58,19 @@ jobs:
distribution: 'adopt'
java-version: '11'
- uses: actions/checkout@v2
- uses: actions/cache@v2

- name: Setup Gradle Dependencies Cache
uses: actions/cache@v3
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-caches-${{ hashFiles('**/*.gradle', '**/*.gradle.kts') }}

- name: Setup Gradle Wrapper Cache
uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-${{ matrix.api-level }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-${{ matrix.api-level }}-gradle-
path: ~/.gradle/wrapper
key: ${{ runner.os }}-gradle-wrapper-${{ hashFiles('**/gradle/wrapper/gradle-wrapper.properties') }}

- name: run tests
uses: reactivecircus/android-emulator-runner@v2
with:
Expand Down

0 comments on commit 6d810ba

Please sign in to comment.