[K/N] XCTest support build script fix
Fix XCTest destination in the cinterop setup. `-iframework` should point to the directory containing the framework. Co-authored-by: Cristian Garcia <Cristian.Garcia-Marin@jetbrains.com> Merge-request: KT-MR-14804 Merged-by: Pavel Punegov <Pavel.Punegov@jetbrains.com>
This commit is contained in:
committed by
Space Team
parent
aaea1d6af2
commit
84e1ab1663
@@ -79,16 +79,16 @@ abstract class DevFrameworkPathValueSource : ValueSource<String, DevFrameworkPat
|
||||
*/
|
||||
fun registerCopyFrameworkTask(target: KonanTarget): TaskProvider<Sync> =
|
||||
tasks.register<Sync>("${target}FrameworkCopy") {
|
||||
into(layout.buildDirectory.dir("$target/Frameworks"))
|
||||
from(
|
||||
providers.of(DevFrameworkPathValueSource::class) {
|
||||
parameters {
|
||||
konanTarget = target
|
||||
}
|
||||
}.map {
|
||||
Paths.get(it).resolve("XCTest.framework")
|
||||
}
|
||||
)
|
||||
into(layout.buildDirectory.dir("$target/Frameworks/XCTest.framework"))
|
||||
) {
|
||||
include("XCTest.framework/**")
|
||||
}
|
||||
}
|
||||
|
||||
// endregion
|
||||
@@ -167,7 +167,7 @@ nativeTargets.forEach { target ->
|
||||
builtBy(cinteropKlibTask)
|
||||
}
|
||||
// Add a path to a directory that contains copied framework to share it with test infrastructure
|
||||
add(kotlinTestNativeXCTest.name, frameworkCopyTask.map { it.destinationDir.parentFile }) {
|
||||
add(kotlinTestNativeXCTest.name, frameworkCopyTask.map { it.destinationDir }) {
|
||||
classifier = "${targetName}Frameworks"
|
||||
builtBy(frameworkCopyTask)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user