@@ -5,8 +5,7 @@ plugins {
55}
66
77val moduleName = " com.github.kotlin_graphics.kotlin_unsigned"
8- val kot = " org.jetbrains.kotlin:kotlin"
9- val kotlintest_version = " 4.0.5"
8+ val kotestVersion = " 4.0.5"
109
1110repositories {
1211 mavenCentral()
@@ -23,7 +22,7 @@ dependencies {
2322 components { withModule<ModularKotlinRule >(kotlin(" stdlib-jdk8" )) }
2423
2524 listOf (" runner-junit5" , " assertions-core" /* , "property"*/ ).forEach {
26- testImplementation(" io.kotest:kotest-$it -jvm:$kotlintest_version " )
25+ testImplementation(" io.kotest:kotest-$it -jvm:$kotestVersion " )
2726 }
2827}
2928
@@ -81,18 +80,15 @@ tasks.compileJava {
8180 options.compilerArgs = listOf (" --patch-module" , " $moduleName =${sourceSets.main.get().output.asPath} " )
8281}
8382
84- tasks.withType<Test > {
85- useJUnitPlatform()
86- }
83+ tasks.withType<Test > { useJUnitPlatform() }
8784
8885// == Add access to the 'modular' variant of kotlin("stdlib"): Put this into a buildSrc plugin and reuse it in all your subprojects
8986configurations.all {
90- if (name.toLowerCase().endsWith(" compileclasspath" ) || name.toLowerCase().endsWith(" runtimeclasspath" )) {
87+ val n = name.toLowerCase()
88+ if (n.endsWith(" compileclasspath" ) || n.endsWith(" runtimeclasspath" ))
9189 attributes.attribute(LibraryElements .LIBRARY_ELEMENTS_ATTRIBUTE , objects.named(" modular-jar" ))
92- }
93- if (name.toLowerCase().endsWith(" compile" ) || name.toLowerCase().endsWith(" runtime" )) {
90+ if (n.endsWith(" compile" ) || n.endsWith(" runtime" ))
9491 isCanBeConsumed = false
95- }
9692}
9793
9894abstract class ModularJarCompatibilityRule : AttributeCompatibilityRule <LibraryElements > {
0 commit comments