diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index b905139..da7f78f 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -4,7 +4,7 @@ on: [ push, pull_request ] jobs: check: - runs-on: ubuntu-latest + runs-on: macos-latest steps: - uses: actions/checkout@v2 @@ -32,7 +32,7 @@ jobs: publish: needs: check if: github.ref == 'refs/heads/master' && github.event_name == 'push' && needs.check.result == 'success' - runs-on: ubuntu-latest + runs-on: macos-latest steps: - uses: actions/checkout@v2 diff --git a/build.gradle.kts b/build.gradle.kts index c0eb4fa..92d03c9 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -71,6 +71,8 @@ subprojects { browser() nodejs() } + + ios() } } diff --git a/kotlin-result-coroutines/src/iosTest/kotlin/com/github/michaelbull/result/coroutines/RunBlockingTest.kt b/kotlin-result-coroutines/src/iosTest/kotlin/com/github/michaelbull/result/coroutines/RunBlockingTest.kt new file mode 100644 index 0000000..ee1f583 --- /dev/null +++ b/kotlin-result-coroutines/src/iosTest/kotlin/com/github/michaelbull/result/coroutines/RunBlockingTest.kt @@ -0,0 +1,11 @@ +package com.github.michaelbull.result.coroutines + +import kotlinx.coroutines.CoroutineScope +import kotlinx.coroutines.runBlocking +import kotlin.coroutines.CoroutineContext + +actual fun runBlockingTest(context: CoroutineContext, testBody: suspend CoroutineScope.() -> Unit) { + runBlocking { + testBody(this) + } +} diff --git a/kotlin-result/src/iosMain/kotlin/com/github/michaelbull/result/BindException.kt b/kotlin-result/src/iosMain/kotlin/com/github/michaelbull/result/BindException.kt new file mode 100644 index 0000000..1ea8893 --- /dev/null +++ b/kotlin-result/src/iosMain/kotlin/com/github/michaelbull/result/BindException.kt @@ -0,0 +1,3 @@ +package com.github.michaelbull.result + +internal actual object BindException : Exception()