IDEA plugin: Use new test binary getter in project templates

Issue #KT-31724 fixed
This commit is contained in:
Ilya Matveev
2019-06-03 20:04:46 +07:00
parent 2ab0760e35
commit e8e2a5654e
@@ -185,12 +185,12 @@ class KotlinGradleMobileSharedMultiplatformModuleBuilder : KotlinGradleAbstractM
task $nativeTestName {
def device = project.findProperty("${nativeTargetName}Device")?.toString() ?: "iPhone 8"
dependsOn kotlin.targets.$nativeTargetName.binaries.getExecutable('test', 'DEBUG').linkTaskName
dependsOn kotlin.targets.$nativeTargetName.binaries.getTest('DEBUG').linkTaskName
group = JavaBasePlugin.VERIFICATION_GROUP
description = "Runs tests for target '$nativeTargetName' on an iOS simulator"
doLast {
def binary = kotlin.targets.$nativeTargetName.binaries.getExecutable('test', 'DEBUG').outputFile
def binary = kotlin.targets.$nativeTargetName.binaries.getTest('DEBUG').outputFile
exec {
commandLine 'xcrun', 'simctl', 'spawn', device, binary.absolutePath
}