Update CI Java version

This commit is contained in:
Stypox 2023-04-20 11:31:45 +02:00
parent 78e1e0508e
commit 69ef4a987e
No known key found for this signature in database
GPG Key ID: 4BDF1B40A49FDD23
2 changed files with 18 additions and 13 deletions

View File

@ -44,10 +44,10 @@ jobs:
if: github.event_name == 'pull_request'
run: git checkout -B ${{ github.head_ref }}
- name: set up JDK 11
- name: set up JDK 17
uses: actions/setup-java@v3
with:
java-version: 11
java-version: 17
distribution: "temurin"
cache: 'gradle'
@ -66,8 +66,13 @@ jobs:
timeout-minutes: 20
strategy:
matrix:
# api-level 19 is min sdk, but throws errors related to desugaring
api-level: [ 21, 29 ]
include:
- api-level: 21
target: default
arch: x86
- api-level: 33
target: google_apis # emulator API 33 only exists with Google APIs
arch: x86_64
permissions:
contents: read
@ -75,10 +80,10 @@ jobs:
steps:
- uses: actions/checkout@v3
- name: set up JDK 11
- name: set up JDK 17
uses: actions/setup-java@v3
with:
java-version: 11
java-version: 17
distribution: "temurin"
cache: 'gradle'
@ -86,8 +91,8 @@ jobs:
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: ${{ matrix.api-level }}
# workaround to emulator bug: https://github.com/ReactiveCircus/android-emulator-runner/issues/160
emulator-build: 7425822
target: ${{ matrix.target }}
arch: ${{ matrix.arch }}
script: ./gradlew connectedCheck --stacktrace
- name: Upload test report when tests fail # because the printed out stacktrace (console) is too short, see also #7553
@ -108,10 +113,10 @@ jobs:
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
- name: Set up JDK 11
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: 11 # Sonar requires JDK 11
java-version: 17
distribution: "temurin"
cache: 'gradle'

View File

@ -80,13 +80,13 @@ android {
// Flag to enable support for the new language APIs
coreLibraryDesugaringEnabled true
sourceCompatibility JavaVersion.VERSION_11
targetCompatibility JavaVersion.VERSION_11
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
encoding 'utf-8'
}
kotlinOptions {
jvmTarget = JavaVersion.VERSION_11
jvmTarget = JavaVersion.VERSION_17
}
sourceSets {