Skip to content

Commit

Permalink
Added native tests
Browse files Browse the repository at this point in the history
  • Loading branch information
corneil committed Mar 16, 2024
1 parent 4f30d67 commit b6fa3e9
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions gradle/platform.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,12 @@ targetList.forEach { target ->
}
}

static def configureNative(srcSetMain, srcSetTest) {
srcSetMain.kotlin.srcDirs = ['src/nativeMain/kotlin']
srcSetTest.kotlin.srcDirs = ['src/nativeTest/kotlin']
}


logger.lifecycle(":platforms from: ${os.displayName} on ${arch.displayName}:${buildTargetList}=${useTarget}")
kotlin {

Expand Down Expand Up @@ -159,5 +165,14 @@ kotlin {
implementation kotlin('test-annotations-common')
}
}
if (useTarget['linux']) {
configureNative(linuxMain, linuxTest)
}
if (useTarget['mingw']) {
configureNative(mingwX64Main, mingwX64Test)
}
if (useTarget['macos']) {
configureNative(macosMain, macosTest)
}
}
}

0 comments on commit b6fa3e9

Please sign in to comment.