|
| 1 | +plugins { |
| 2 | + java |
| 3 | + kotlin("multiplatform") |
| 4 | +} |
| 5 | + |
| 6 | +repositories { |
| 7 | + maven("https://dl.bintray.com/spekframework/spek-dev") |
| 8 | +} |
| 9 | + |
| 10 | +kotlin { |
| 11 | + jvm() |
| 12 | + js(IR) { |
| 13 | + binaries.executable() |
| 14 | + } |
| 15 | + |
| 16 | + iosArm64("ios") |
| 17 | + iosX64("iosSim") |
| 18 | + macosX64("macos") |
| 19 | + mingwX64("win") |
| 20 | + wasm32("wasm") |
| 21 | + linuxArm32Hfp("linArm32") |
| 22 | + linuxMips32("linMips32") |
| 23 | + linuxMipsel32("linMipsel32") |
| 24 | + linuxX64("lin64") |
| 25 | + |
| 26 | + sourceSets { |
| 27 | + commonMain { |
| 28 | + dependencies { |
| 29 | + implementation(project(":redux-kotlin")) |
| 30 | + } |
| 31 | + } |
| 32 | + commonTest { |
| 33 | + kotlin.srcDir("src/test/kotlin") |
| 34 | + dependencies { |
| 35 | + implementation(kotlin("test-common")) |
| 36 | + implementation(kotlin("test-annotations-common")) |
| 37 | + implementation("org.spekframework.spek2:spek-dsl-metadata:${Versions.spek}") |
| 38 | + implementation("ch.tutteli.atrium:atrium-cc-en_GB-robstoll-common:${Versions.atrium}") |
| 39 | + implementation("io.mockk:mockk-common:${Versions.mockk}") |
| 40 | + } |
| 41 | + } |
| 42 | + val jvmTest by getting { |
| 43 | + dependencies { |
| 44 | + implementation(kotlin("test")) |
| 45 | + implementation(kotlin("test-junit")) |
| 46 | + implementation("org.spekframework.spek2:spek-dsl-jvm:${Versions.spek}") |
| 47 | + implementation("ch.tutteli.atrium:atrium-cc-en_GB-robstoll:${Versions.atrium}") |
| 48 | + implementation("io.mockk:mockk:${Versions.mockk}") |
| 49 | + |
| 50 | + runtimeOnly("org.spekframework.spek2:spek-runner-junit5:${Versions.spek}") |
| 51 | + runtimeOnly("org.jetbrains.kotlin:kotlin-reflect") |
| 52 | + } |
| 53 | + } |
| 54 | + val jsTest by getting { |
| 55 | + dependencies { |
| 56 | + implementation(kotlin("test-js")) |
| 57 | + implementation(kotlin("stdlib-js")) |
| 58 | + } |
| 59 | + } |
| 60 | + |
| 61 | + val iosMain by getting |
| 62 | + val iosTest by getting |
| 63 | + val iosSimMain by getting { dependsOn(iosMain) } |
| 64 | + val iosSimTest by getting { dependsOn(iosTest) } |
| 65 | + } |
| 66 | +} |
| 67 | + |
| 68 | +tasks { |
| 69 | + val jvmTest by getting(Test::class) { |
| 70 | + useJUnitPlatform { |
| 71 | + includeEngines("spek2") |
| 72 | + } |
| 73 | + } |
| 74 | +} |
0 commit comments