Refactor TorRuntime.Environment
to use new ResourceLoader.Tor
abstraction
#368
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: Test | |
on: [ pull_request ] | |
env: | |
GRADLE_OPTS: -Dorg.gradle.daemon=false -Dkotlin.incremental=false -Dorg.gradle.jvmargs="-XX:+HeapDumpOnOutOfMemoryError -XX:MetaspaceSize=1g" | |
jobs: | |
check: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ macos-latest, ubuntu-latest, windows-latest ] | |
java-version: [ 11, 19 ] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
- name: Validate Gradle Wrapper | |
uses: gradle/actions/wrapper-validation@v3 | |
- name: Setup JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'zulu' | |
java-version: ${{ matrix.java-version }} | |
- name: Run macOS Tests [ Java 11 ] | |
if: matrix.os == 'macos-latest' && matrix.java-version == 11 | |
run: > | |
./gradlew check --stacktrace | |
-PKMP_TARGETS="IOS_ARM64,IOS_X64,IOS_SIMULATOR_ARM64,JS,JVM,WASM_JS,WASM_WASI" | |
- name: Run macOS Tests [ Java 19 ] | |
if: matrix.os == 'macos-latest' && matrix.java-version == 19 | |
run: > | |
./gradlew check --stacktrace | |
-PKMP_TARGETS="JVM,MACOS_ARM64,MACOS_X64,TVOS_ARM64,TVOS_X64,TVOS_SIMULATOR_ARM64,WATCHOS_ARM32,WATCHOS_ARM64,WATCHOS_DEVICE_ARM64,WATCHOS_X64,WATCHOS_SIMULATOR_ARM64" | |
- name: Run Linux Tests [ Java 11 ] | |
if: matrix.os == 'ubuntu-latest' && matrix.java-version == 11 | |
run: > | |
./gradlew check --stacktrace | |
-PKMP_TARGETS="JS,JVM,WASM_JS,WASM_WASI" | |
- name: Run Linux Tests [ Java 19 ] | |
if: matrix.os == 'ubuntu-latest' && matrix.java-version == 19 | |
run: > | |
./gradlew check --stacktrace | |
-PKMP_TARGETS="ANDROID,ANDROID_ARM32,ANDROID_ARM64,ANDROID_X64,ANDROID_X86,JVM,LINUX_ARM64,LINUX_X64" | |
- name: Run Windows Tests [ Java 11 ] | |
if: matrix.os == 'windows-latest' && matrix.java-version == 11 | |
run: > | |
./gradlew check --stacktrace | |
-PKMP_TARGETS="JS,JVM,WASM_JS,WASM_WASI" | |
- name: Run Windows Tests [ Java 19 ] | |
if: matrix.os == 'windows-latest' && matrix.java-version == 19 | |
run: > | |
./gradlew check --stacktrace | |
-PKMP_TARGETS="JVM,MINGW_X64" | |
- name: Upload Test Reports | |
uses: actions/upload-artifact@v4 | |
if: ${{ always() }} | |
with: | |
name: test-report-${{ matrix.os }}-java${{ matrix.java-version }} | |
path: '**/build/reports/tests/**' | |
retention-days: 1 | |
android-check: | |
strategy: | |
fail-fast: false | |
matrix: | |
api-level: [ 21, 24, 29, 33 ] | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
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: Validate Gradle Wrapper | |
uses: gradle/actions/wrapper-validation@v3 | |
- name: Setup JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'zulu' | |
java-version: 17 | |
- name: Run Android Instrumented Tests | |
uses: reactivecircus/android-emulator-runner@v2 | |
with: | |
emulator-boot-timeout: 300 # 5 minutes | |
api-level: ${{ matrix.api-level }} | |
arch: x86_64 | |
script: ./gradlew connectedCheck -PKMP_TARGETS="ANDROID,JVM" | |
- name: Upload Test Reports | |
uses: actions/upload-artifact@v4 | |
if: ${{ always() }} | |
with: | |
name: test-report-android-${{ matrix.api-level }} | |
path: '**/build/reports/androidTests/**' | |
retention-days: 1 |