Skip to content

Commit

Permalink
Fix kmm unit test action
Browse files Browse the repository at this point in the history
* Fix kmm unit test action

* Add unit test action to pull request
  • Loading branch information
osakila authored Nov 22, 2023
1 parent 0fec02e commit 1f3a595
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 2 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/buildAndTest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
branches: [ "main" ]
paths:
- 'kotlin-multiplatform/**'
workflow_dispatch:

permissions:
contents: read
Expand All @@ -23,3 +24,9 @@ jobs:
uses: gradle/gradle-build-action@67421db6bd0bf253fb4bd25b31ebb98943c375e1
with:
arguments: publishToMavenLocal podPublishXCFramework testReleaseUnitTest
- name: Archive code coverage results
if: always()
uses: actions/upload-artifact@v1
with:
name: code-coverage-report
path: kotlin-multiplatform/build/reports/tests/testReleaseUnitTest
29 changes: 29 additions & 0 deletions .github/workflows/test-pull-request.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: pull request unit test

on:
workflow_dispatch:
pull_request:

permissions:
contents: read

jobs:
build:
runs-on: macos-12
steps:
- uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
- name: Build and Test with Gradle
uses: gradle/gradle-build-action@67421db6bd0bf253fb4bd25b31ebb98943c375e1
with:
arguments: testReleaseUnitTest
- name: Archive code coverage results
if: always()
uses: actions/upload-artifact@v1
with:
name: code-coverage-report
path: kotlin-multiplatform/build/reports/tests/testReleaseUnitTest
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ class LimitlessIntervalCaptureTest {
}

runBlocking {
withTimeout(2000) {
withTimeout(5000) {
deferred.await()
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ class VideoCaptureTest {
}

runBlocking {
withTimeout(2000) {
withTimeout(5000) {
deferred.await()
}
}
Expand Down

0 comments on commit 1f3a595

Please sign in to comment.