Ahmed Ibrahim
02/17/2020, 1:53 PMunitTests.all {
useJUnitPlatform()
}
In Kotlin script though I'm doing
testOptions {
unitTests.all(closureOf<Test> {
useJUnitPlatform()
} as Closure<Test>)
}
However I'm a bit annoyed from the as
clause as without it I get a compile error, so my question is there a way I could do that without explicitly casting to Closure<Test>
?mbonnin
02/17/2020, 2:05 PMtestOptions {
unitTests.all(KotlinClosure1<Test, Test>({this}, this, this))
}
But I'm not sure it's much better actually. I would just stick to the cast and file a bug the AGP team for them to provide better Kotlin apiAhmed Ibrahim
02/17/2020, 2:07 PMMatej Drobnič
02/18/2020, 5:57 AMMatej Drobnič
02/18/2020, 5:57 AMtapchicoma
02/18/2020, 12:42 PMAhmed Ibrahim
02/23/2020, 12:06 PMAhmed Ibrahim
02/23/2020, 12:19 PMMatej Drobnič
02/24/2020, 6:28 AMMatej Drobnič
02/24/2020, 6:29 AMAhmed Ibrahim
02/24/2020, 11:09 AMMatej Drobnič
02/24/2020, 11:10 AM