FIR LT: Add box inline tests for FIR + LT (failing on SMAP so far)

This commit is contained in:
Ilya Chernikov
2022-02-19 21:08:46 +01:00
committed by teamcity
parent ae10346d75
commit bd60d4b2a6
4 changed files with 5701 additions and 1 deletions
@@ -37,7 +37,7 @@ abstract class ObjectTransformer<out T : TransformationInfo>(@JvmField val trans
val classBuilder = state.factory.newVisitor(
JvmDeclarationOrigin.NO_ORIGIN,
Type.getObjectType(transformationInfo.newClassName),
listOf(inliningContext.callSiteInfo.file!!)
listOfNotNull(inliningContext.callSiteInfo.file)
)
return RemappingClassBuilder(
@@ -6,6 +6,7 @@
package org.jetbrains.kotlin.test.runners.codegen
import org.jetbrains.kotlin.test.builders.TestConfigurationBuilder
import org.jetbrains.kotlin.test.directives.FirDiagnosticsDirectives
open class AbstractBlackBoxInlineCodegenTest : AbstractBlackBoxCodegenTest() {
override fun configure(builder: TestConfigurationBuilder) {
@@ -27,3 +28,15 @@ open class AbstractFirBlackBoxInlineCodegenTest : AbstractFirBlackBoxCodegenTest
builder.useInlineHandlers()
}
}
open class AbstractFirLightTreeBlackBoxInlineCodegenTest : AbstractFirBlackBoxCodegenTest() {
override fun configure(builder: TestConfigurationBuilder) {
super.configure(builder)
with(builder) {
useInlineHandlers()
defaultDirectives {
+FirDiagnosticsDirectives.USE_LIGHT_TREE
}
}
}
}
@@ -231,6 +231,10 @@ fun generateJUnit5CompilerTests(args: Array<String>) {
model("codegen/boxInline")
}
testClass<AbstractFirLightTreeBlackBoxInlineCodegenTest> {
model("codegen/boxInline")
}
testClass<AbstractFirSteppingTest> {
model("debug/stepping")
}