#AK - init #1
This file contains hidden or 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 & lint Kotlin codebase | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| branches: | |
| - main | |
| jobs: | |
| lint: | |
| name: Lint & code style | |
| timeout-minutes: 15 | |
| if: github.event.pull_request.draft == false | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0 | |
| - name: Set up JDK 24 | |
| uses: actions/setup-java@c5195efecf7bdfc987ee8bae7a71cb8b11521c00 # v4.7.1 | |
| with: | |
| java-version: '24' | |
| distribution: 'temurin' | |
| - name: Setup Gradle | |
| uses: gradle/actions/setup-gradle@af1da67850ed9a4cedd57bfd976089dd991e2582 # v4.0.0 | |
| - name: Run Detekt | |
| run: ./gradlew detekt | |
| - name: Run code style check | |
| run: ./gradlew csCheck | |
| test: | |
| name: Tests (${{ matrix.name }}) | |
| timeout-minutes: ${{ matrix.timeout }} | |
| if: github.event.pull_request.draft == false | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - name: JVM & Desktop | |
| os: ubuntu-24.04 | |
| timeout: 15 | |
| command: ./gradlew :shared:desktopTest :composeApp:desktopTest | |
| - name: Android | |
| os: ubuntu-24.04 | |
| timeout: 15 | |
| command: ./gradlew :shared:testDebugUnitTest :composeApp:testDebugUnitTest | |
| - name: iOS Simulator | |
| os: macos-15 | |
| timeout: 20 | |
| command: ./gradlew :shared:iosSimulatorArm64Test :composeApp:iosSimulatorArm64Test | |
| steps: | |
| - uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0 | |
| - name: Set up JDK 24 | |
| uses: actions/setup-java@c5195efecf7bdfc987ee8bae7a71cb8b11521c00 # v4.7.1 | |
| with: | |
| java-version: '24' | |
| distribution: 'temurin' | |
| - name: Setup Gradle | |
| uses: gradle/actions/setup-gradle@af1da67850ed9a4cedd57bfd976089dd991e2582 # v4.0.0 | |
| - name: Run tests | |
| run: ${{ matrix.command }} |