Add module-info to kotlin-test-* framework adapter artifacts

#KT-21266
This commit is contained in:
Ilya Gorbunov
2020-04-23 00:55:52 +03:00
parent 92c4ccc65f
commit 843829116d
6 changed files with 83 additions and 3 deletions
+19 -1
View File
@@ -6,14 +6,28 @@ configureJvm6Project(project)
configurePublishing(project)
ext.javaHome = JDK_17
def includeJava9 = BuildPropertiesExtKt.getIncludeJava9(project.kotlinBuildProperties)
sourceSets {
if (includeJava9) {
java9
}
}
dependencies {
expectedBy project(':kotlin-test:kotlin-test-annotations-common')
compile project(':kotlin-test:kotlin-test-jvm')
compile('org.testng:testng:6.13.1')
if (includeJava9) {
java9CompileOnly('org.testng:testng:7.0.0')
}
}
jar {
manifestAttributes(manifest, project, 'Test')
manifestAttributes(manifest, project, 'Test', true)
if (includeJava9) {
from sourceSets.java9.output
}
}
artifacts {
@@ -31,6 +45,10 @@ compileTestKotlin {
kotlinOptions.freeCompilerArgs = ["-Xallow-kotlin-package"]
}
if (includeJava9) {
compileJava9Sources(project, 'kotlin.test.testng')
}
test {
useTestNG()
}
@@ -0,0 +1,11 @@
module kotlin.test.testng {
requires transitive kotlin.stdlib;
requires transitive kotlin.test;
requires org.testng; // automatic module name in testng manifest since 7.0.0
// won't work with earlier versions, where just 'testng' name was inferred from the artifact name
exports kotlin.test.testng;
provides kotlin.test.AsserterContributor with kotlin.test.testng.TestNGContributor;
}