[Native][tests] Use the single 'generateTests' task

This commit is contained in:
Dmitriy Dolovov
2021-11-11 14:50:18 +03:00
parent 54b09810f0
commit ce4d2093cc
4 changed files with 19 additions and 41 deletions
@@ -1,29 +0,0 @@
/*
* Copyright 2010-2021 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
package org.jetbrains.kotlin.generators.tests
import org.jetbrains.kotlin.generators.generateTestGroupSuiteWithJUnit5
import org.jetbrains.kotlin.generators.model.annotation
import org.jetbrains.kotlin.konan.blackboxtest.AbstractNativeBlackBoxTest
import org.jetbrains.kotlin.konan.blackboxtest.group.ExtTestCaseGroupProvider
fun main() {
System.setProperty("java.awt.headless", "true")
generateTestGroupSuiteWithJUnit5 {
testGroup("native/native.tests/ext-tests-gen", "compiler/testData") {
testClass<AbstractNativeBlackBoxTest>(
suiteTestClassName = "NativeExtBlackBoxTestGenerated",
annotations = listOf(
annotation(CustomNativeBlackBoxTestCaseGroupProvider::class.java, ExtTestCaseGroupProvider::class.java)
)
) {
model("codegen/box")
model("codegen/boxInline")
}
}
}
}
@@ -6,12 +6,28 @@
package org.jetbrains.kotlin.generators.tests
import org.jetbrains.kotlin.generators.generateTestGroupSuiteWithJUnit5
import org.jetbrains.kotlin.generators.model.annotation
import org.jetbrains.kotlin.konan.blackboxtest.AbstractNativeBlackBoxTest
import org.jetbrains.kotlin.konan.blackboxtest.group.ExtTestCaseGroupProvider
fun main() {
System.setProperty("java.awt.headless", "true")
generateTestGroupSuiteWithJUnit5 {
// External box tests.
testGroup("native/native.tests/tests-gen", "compiler/testData") {
testClass<AbstractNativeBlackBoxTest>(
suiteTestClassName = "NativeExtBlackBoxTestGenerated",
annotations = listOf(
annotation(CustomNativeBlackBoxTestCaseGroupProvider::class.java, ExtTestCaseGroupProvider::class.java)
)
) {
model("codegen/box")
model("codegen/boxInline")
}
}
// Samples (how to utilize abilities of new test infrastructure).
testGroup("native/native.tests/tests-gen", "native/native.tests/testData") {
testClass<AbstractNativeBlackBoxTest> {
model("samples")