diff --git a/.space/CODEOWNERS b/.space/CODEOWNERS index 61dd27168d9..bb34c33e015 100644 --- a/.space/CODEOWNERS +++ b/.space/CODEOWNERS @@ -143,7 +143,6 @@ /compiler/testData/ir/irJsText/ "Kotlin Compiler Core" /compiler/testData/ir/irText/ "Kotlin Compiler Core" /compiler/testData/ir/klibLayout/ "Kotlin Native" -/compiler/testData/ir/loweredIr/interpreter/ "Kotlin JVM" /compiler/testData/ir/sourceRanges/ "Kotlin Compiler Core" /compiler/testData/javaModules/ "Kotlin JVM" /compiler/testData/klibABI/ "Kotlin Native" diff --git a/compiler/fir/fir2ir/tests-gen/org/jetbrains/kotlin/test/runners/codegen/FirBlackBoxCodegenTestGenerated.java b/compiler/fir/fir2ir/tests-gen/org/jetbrains/kotlin/test/runners/codegen/FirBlackBoxCodegenTestGenerated.java index 32ac5071f09..64289f3c3e9 100644 --- a/compiler/fir/fir2ir/tests-gen/org/jetbrains/kotlin/test/runners/codegen/FirBlackBoxCodegenTestGenerated.java +++ b/compiler/fir/fir2ir/tests-gen/org/jetbrains/kotlin/test/runners/codegen/FirBlackBoxCodegenTestGenerated.java @@ -263,12 +263,6 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT runTest("compiler/testData/codegen/box/annotations/kt25489.kt"); } - @Test - @TestMetadata("kt55108.kt") - public void testKt55108() throws Exception { - runTest("compiler/testData/codegen/box/annotations/kt55108.kt"); - } - @Test @TestMetadata("mustBeDocumented.kt") public void testMustBeDocumented() throws Exception { @@ -8295,12 +8289,6 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT runTest("compiler/testData/codegen/box/constants/foldingBinaryOpsUnsignedConst.kt"); } - @Test - @TestMetadata("kt53480.kt") - public void testKt53480() throws Exception { - runTest("compiler/testData/codegen/box/constants/kt53480.kt"); - } - @Test @TestMetadata("kt9532.kt") public void testKt9532() throws Exception { @@ -17123,12 +17111,6 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT runTest("compiler/testData/codegen/box/evaluate/plus.kt"); } - @Test - @TestMetadata("referenceNameFromStaticInDifferentModule.kt") - public void testReferenceNameFromStaticInDifferentModule() throws Exception { - runTest("compiler/testData/codegen/box/evaluate/referenceNameFromStaticInDifferentModule.kt"); - } - @Test @TestMetadata("rem.kt") public void testRem() throws Exception { @@ -17141,18 +17123,6 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT runTest("compiler/testData/codegen/box/evaluate/simpleCallBinary.kt"); } - @Test - @TestMetadata("stringConcatenationWithObject.kt") - public void testStringConcatenationWithObject() throws Exception { - runTest("compiler/testData/codegen/box/evaluate/stringConcatenationWithObject.kt"); - } - - @Test - @TestMetadata("thisPlusString.kt") - public void testThisPlusString() throws Exception { - runTest("compiler/testData/codegen/box/evaluate/thisPlusString.kt"); - } - @Test @TestMetadata("unaryMinus.kt") public void testUnaryMinus() throws Exception { @@ -28106,6 +28076,170 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT } } + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter") + @TestDataPath("$PROJECT_ROOT") + public class InvolvesIrInterpreter { + @Test + public void testAllFilesPresentInInvolvesIrInterpreter() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true); + } + + @Test + @TestMetadata("kt53480.kt") + public void testKt53480() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/kt53480.kt"); + } + + @Test + @TestMetadata("kt55108.kt") + public void testKt55108() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/kt55108.kt"); + } + + @Test + @TestMetadata("referenceNameFromStaticInDifferentModule.kt") + public void testReferenceNameFromStaticInDifferentModule() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/referenceNameFromStaticInDifferentModule.kt"); + } + + @Test + @TestMetadata("stringConcatenationWithObject.kt") + public void testStringConcatenationWithObject() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/stringConcatenationWithObject.kt"); + } + + @Test + @TestMetadata("thisPlusString.kt") + public void testThisPlusString() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/thisPlusString.kt"); + } + + @Test + @TestMetadata("useCorrectToString.kt") + public void testUseCorrectToString() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/useCorrectToString.kt"); + } + + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck") + @TestDataPath("$PROJECT_ROOT") + public class DumpIrAndCheck { + @Test + public void testAllFilesPresentInDumpIrAndCheck() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true); + } + + @Test + @TestMetadata("booleanOperations.kt") + public void testBooleanOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/booleanOperations.kt"); + } + + @Test + @TestMetadata("byteOperations.kt") + public void testByteOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/byteOperations.kt"); + } + + @Test + @TestMetadata("charOperations.kt") + public void testCharOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/charOperations.kt"); + } + + @Test + @TestMetadata("constTrimIndent.kt") + public void testConstTrimIndent() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/constTrimIndent.kt"); + } + + @Test + @TestMetadata("constTrimMargin.kt") + public void testConstTrimMargin() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/constTrimMargin.kt"); + } + + @Test + @TestMetadata("doubleOperations.kt") + public void testDoubleOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/doubleOperations.kt"); + } + + @Test + @TestMetadata("enumName.kt") + public void testEnumName() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/enumName.kt"); + } + + @Test + @TestMetadata("enumRecursiveName.kt") + public void testEnumRecursiveName() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/enumRecursiveName.kt"); + } + + @Test + @TestMetadata("floatOperations.kt") + public void testFloatOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/floatOperations.kt"); + } + + @Test + @TestMetadata("ifConstVal.kt") + public void testIfConstVal() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/ifConstVal.kt"); + } + + @Test + @TestMetadata("intOperations.kt") + public void testIntOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/intOperations.kt"); + } + + @Test + @TestMetadata("kCallableName.kt") + public void testKCallableName() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/kCallableName.kt"); + } + + @Test + @TestMetadata("kt53272.kt") + public void testKt53272() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/kt53272.kt"); + } + + @Test + @TestMetadata("longOperations.kt") + public void testLongOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/longOperations.kt"); + } + + @Test + @TestMetadata("shortOperations.kt") + public void testShortOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/shortOperations.kt"); + } + + @Test + @TestMetadata("stdlibConst.kt") + public void testStdlibConst() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/stdlibConst.kt"); + } + + @Test + @TestMetadata("stringOperations.kt") + public void testStringOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/stringOperations.kt"); + } + + @Test + @TestMetadata("unsignedConst.kt") + public void testUnsignedConst() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/unsignedConst.kt"); + } + } + } + @Nested @TestMetadata("compiler/testData/codegen/box/ir") @TestDataPath("$PROJECT_ROOT") diff --git a/compiler/fir/fir2ir/tests-gen/org/jetbrains/kotlin/test/runners/ir/LoweredIrInterpreterTestGenerated.java b/compiler/fir/fir2ir/tests-gen/org/jetbrains/kotlin/test/runners/ir/LoweredIrInterpreterTestGenerated.java deleted file mode 100644 index 5761d6879ce..00000000000 --- a/compiler/fir/fir2ir/tests-gen/org/jetbrains/kotlin/test/runners/ir/LoweredIrInterpreterTestGenerated.java +++ /dev/null @@ -1,151 +0,0 @@ -/* - * Copyright 2010-2023 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.test.runners.ir; - -import com.intellij.testFramework.TestDataPath; -import org.jetbrains.kotlin.test.util.KtTestUtil; -import org.jetbrains.kotlin.test.TargetBackend; -import org.jetbrains.kotlin.test.TestMetadata; -import org.junit.jupiter.api.Nested; -import org.junit.jupiter.api.Test; - -import java.io.File; -import java.util.regex.Pattern; - -/** This class is generated by {@link org.jetbrains.kotlin.test.generators.GenerateCompilerTestsKt}. DO NOT MODIFY MANUALLY */ -@SuppressWarnings("all") -@TestMetadata("compiler/testData/ir/loweredIr") -@TestDataPath("$PROJECT_ROOT") -public class LoweredIrInterpreterTestGenerated extends AbstractLoweredIrInterpreterTest { - @Test - public void testAllFilesPresentInLoweredIr() throws Exception { - KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/ir/loweredIr"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true); - } - - @Nested - @TestMetadata("compiler/testData/ir/loweredIr/interpreter") - @TestDataPath("$PROJECT_ROOT") - public class Interpreter { - @Test - public void testAllFilesPresentInInterpreter() throws Exception { - KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/ir/loweredIr/interpreter"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true); - } - - @Test - @TestMetadata("booleanOperations.kt") - public void testBooleanOperations() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/booleanOperations.kt"); - } - - @Test - @TestMetadata("byteOperations.kt") - public void testByteOperations() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/byteOperations.kt"); - } - - @Test - @TestMetadata("charOperations.kt") - public void testCharOperations() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/charOperations.kt"); - } - - @Test - @TestMetadata("constTrimIndent.kt") - public void testConstTrimIndent() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/constTrimIndent.kt"); - } - - @Test - @TestMetadata("constTrimMargin.kt") - public void testConstTrimMargin() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/constTrimMargin.kt"); - } - - @Test - @TestMetadata("doubleOperations.kt") - public void testDoubleOperations() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/doubleOperations.kt"); - } - - @Test - @TestMetadata("enumName.kt") - public void testEnumName() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/enumName.kt"); - } - - @Test - @TestMetadata("enumRecursiveName.kt") - public void testEnumRecursiveName() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/enumRecursiveName.kt"); - } - - @Test - @TestMetadata("floatOperations.kt") - public void testFloatOperations() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/floatOperations.kt"); - } - - @Test - @TestMetadata("ifConstVal.kt") - public void testIfConstVal() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/ifConstVal.kt"); - } - - @Test - @TestMetadata("intOperations.kt") - public void testIntOperations() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/intOperations.kt"); - } - - @Test - @TestMetadata("kCallableName.kt") - public void testKCallableName() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/kCallableName.kt"); - } - - @Test - @TestMetadata("kt53272.kt") - public void testKt53272() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/kt53272.kt"); - } - - @Test - @TestMetadata("longOperations.kt") - public void testLongOperations() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/longOperations.kt"); - } - - @Test - @TestMetadata("shortOperations.kt") - public void testShortOperations() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/shortOperations.kt"); - } - - @Test - @TestMetadata("stdlibConst.kt") - public void testStdlibConst() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/stdlibConst.kt"); - } - - @Test - @TestMetadata("stringOperations.kt") - public void testStringOperations() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/stringOperations.kt"); - } - - @Test - @TestMetadata("unsignedConst.kt") - public void testUnsignedConst() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/unsignedConst.kt"); - } - - @Test - @TestMetadata("useCorrectToString.kt") - public void testUseCorrectToString() throws Exception { - runTest("compiler/testData/ir/loweredIr/interpreter/useCorrectToString.kt"); - } - } -} diff --git a/compiler/testData/ir/loweredIr/interpreter/booleanOperations.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/booleanOperations.kt similarity index 98% rename from compiler/testData/ir/loweredIr/interpreter/booleanOperations.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/booleanOperations.kt index 54d8237b391..06ea8e77e3b 100644 --- a/compiler/testData/ir/loweredIr/interpreter/booleanOperations.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/booleanOperations.kt @@ -1,3 +1,5 @@ +// TARGET_BACKEND: JVM_IR + const val trueVal = true const val falseVal = false diff --git a/compiler/testData/ir/loweredIr/interpreter/byteOperations.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/byteOperations.kt similarity index 93% rename from compiler/testData/ir/loweredIr/interpreter/byteOperations.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/byteOperations.kt index 30993cf58f7..40540ccce0f 100644 --- a/compiler/testData/ir/loweredIr/interpreter/byteOperations.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/byteOperations.kt @@ -1,3 +1,6 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR + const val minusOneVal = (-1).toByte() const val oneVal = 1.toByte() const val twoVal = 2.toByte() @@ -97,14 +100,14 @@ fun box(): String { if (compareTo7 != 0) return "Fail 1.7" if (compareTo8 != 0) return "Fail 1.8" - if (plus1 != 3) return "Fail 2.1" - if (plus2 != 4) return "Fail 2.2" - if (plus3 != 5) return "Fail 2.3" - if (plus4 != 4) return "Fail 2.4" - if (plus5 != 4) return "Fail 2.5" - if (plus6 != 4) return "Fail 2.6" - if (plus7 != 4) return "Fail 2.7" - if (plus8 != 4) return "Fail 2.8" + if (plus1 != 3) return "Fail 2.1" + if (plus2 != 4) return "Fail 2.2" + if (plus3 != 5) return "Fail 2.3" + if (plus4 != 4) return "Fail 2.4" + if (plus5 != 4) return "Fail 2.5" + if (plus6 != 4) return "Fail 2.6" + if (plus7 != 4.0f) return "Fail 2.7" + if (plus8 != 4.0f) return "Fail 2.8" if (minus1 != -1) return "Fail 3.1" if (minus2 != 0) return "Fail 3.2" diff --git a/compiler/testData/ir/loweredIr/interpreter/charOperations.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/charOperations.kt similarity index 99% rename from compiler/testData/ir/loweredIr/interpreter/charOperations.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/charOperations.kt index 3dfc98bfca5..0d9530b0c85 100644 --- a/compiler/testData/ir/loweredIr/interpreter/charOperations.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/charOperations.kt @@ -1,4 +1,6 @@ +// TARGET_BACKEND: JVM_IR // WITH_STDLIB + const val oneVal = '1' const val twoVal = '2' const val threeVal = '3' diff --git a/compiler/testData/ir/loweredIr/interpreter/constTrimIndent.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/constTrimIndent.kt similarity index 84% rename from compiler/testData/ir/loweredIr/interpreter/constTrimIndent.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/constTrimIndent.kt index 49fbd964445..3ee1fa7c345 100644 --- a/compiler/testData/ir/loweredIr/interpreter/constTrimIndent.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/constTrimIndent.kt @@ -1,4 +1,7 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR // WITH_STDLIB + const val trimIndent = "123".trimIndent() const val complexTrimIndent = """ diff --git a/compiler/testData/ir/loweredIr/interpreter/constTrimMargin.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/constTrimMargin.kt similarity index 88% rename from compiler/testData/ir/loweredIr/interpreter/constTrimMargin.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/constTrimMargin.kt index d104852067a..8f5d7fa307c 100644 --- a/compiler/testData/ir/loweredIr/interpreter/constTrimMargin.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/constTrimMargin.kt @@ -1,4 +1,7 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR // WITH_STDLIB + const val trimMargin = "123".trimMargin() const val trimMarginDefault = """ABC diff --git a/compiler/testData/ir/loweredIr/interpreter/doubleOperations.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/doubleOperations.kt similarity index 93% rename from compiler/testData/ir/loweredIr/interpreter/doubleOperations.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/doubleOperations.kt index 8b43925b820..a703fb55400 100644 --- a/compiler/testData/ir/loweredIr/interpreter/doubleOperations.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/doubleOperations.kt @@ -1,3 +1,6 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR + const val minusOneVal = -1.0 const val oneVal = 1.0 const val twoVal = 2.0 @@ -95,14 +98,14 @@ fun box(): String { if (compareTo7 != 0) return "Fail 1.7" if (compareTo8 != 0) return "Fail 1.8" - if (plus1 != 3) return "Fail 2.1" - if (plus2 != 4) return "Fail 2.2" - if (plus3 != 5) return "Fail 2.3" - if (plus4 != 4) return "Fail 2.4" - if (plus5 != 4) return "Fail 2.5" - if (plus6 != 4) return "Fail 2.6" - if (plus7 != 4) return "Fail 2.7" - if (plus8 != 4) return "Fail 2.8" + if (plus1 != 3) return "Fail 2.1" + if (plus2 != 4) return "Fail 2.2" + if (plus3 != 5) return "Fail 2.3" + if (plus4 != 4) return "Fail 2.4" + if (plus5 != 4) return "Fail 2.5" + if (plus6 != 4) return "Fail 2.6" + if (plus7 != 4.0f) return "Fail 2.7" + if (plus8 != 4.0) return "Fail 2.8" if (minus1 != -1) return "Fail 3.1" if (minus2 != 0) return "Fail 3.2" diff --git a/compiler/testData/ir/loweredIr/interpreter/enumName.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/enumName.kt similarity index 88% rename from compiler/testData/ir/loweredIr/interpreter/enumName.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/enumName.kt index 0b103bc471e..162e67f5edc 100644 --- a/compiler/testData/ir/loweredIr/interpreter/enumName.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/enumName.kt @@ -1,3 +1,6 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR + enum class EnumClass { OK, VALUE, anotherValue, WITH_UNDERSCORE } diff --git a/compiler/testData/ir/loweredIr/interpreter/enumRecursiveName.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/enumRecursiveName.kt similarity index 79% rename from compiler/testData/ir/loweredIr/interpreter/enumRecursiveName.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/enumRecursiveName.kt index 0f91d139461..8fd8f10d98d 100644 --- a/compiler/testData/ir/loweredIr/interpreter/enumRecursiveName.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/enumRecursiveName.kt @@ -1,4 +1,5 @@ -// TARGET_BACKEND: JVM +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR // IGNORE_FIR_DIAGNOSTICS // !DIAGNOSTICS: -UNINITIALIZED_ENUM_ENTRY diff --git a/compiler/testData/ir/loweredIr/interpreter/floatOperations.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/floatOperations.kt similarity index 93% rename from compiler/testData/ir/loweredIr/interpreter/floatOperations.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/floatOperations.kt index cbbb0b66848..fc11715a363 100644 --- a/compiler/testData/ir/loweredIr/interpreter/floatOperations.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/floatOperations.kt @@ -1,3 +1,6 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR + const val minusOneVal = -1.0f const val oneVal = 1.0f const val twoVal = 2.0f @@ -95,14 +98,14 @@ fun box(): String { if (compareTo7 != 0) return "Fail 1.7" if (compareTo8 != 0) return "Fail 1.8" - if (plus1 != 3) return "Fail 2.1" - if (plus2 != 4) return "Fail 2.2" - if (plus3 != 5) return "Fail 2.3" - if (plus4 != 4) return "Fail 2.4" - if (plus5 != 4) return "Fail 2.5" - if (plus6 != 4) return "Fail 2.6" - if (plus7 != 4) return "Fail 2.7" - if (plus8 != 4) return "Fail 2.8" + if (plus1 != 3) return "Fail 2.1" + if (plus2 != 4) return "Fail 2.2" + if (plus3 != 5) return "Fail 2.3" + if (plus4 != 4) return "Fail 2.4" + if (plus5 != 4) return "Fail 2.5" + if (plus6 != 4) return "Fail 2.6" + if (plus7 != 4.0f) return "Fail 2.7" + if (plus8 != 4.0) return "Fail 2.8" if (minus1 != -1) return "Fail 3.1" if (minus2 != 0) return "Fail 3.2" diff --git a/compiler/testData/ir/loweredIr/interpreter/ifConstVal.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/ifConstVal.kt similarity index 92% rename from compiler/testData/ir/loweredIr/interpreter/ifConstVal.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/ifConstVal.kt index df9acd3b5c1..4aadf5ef4e3 100644 --- a/compiler/testData/ir/loweredIr/interpreter/ifConstVal.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/ifConstVal.kt @@ -1,3 +1,6 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR + const val flag = true const val value = 10 const val condition = if (flag) "True" else "Error" diff --git a/compiler/testData/ir/loweredIr/interpreter/intOperations.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/intOperations.kt similarity index 93% rename from compiler/testData/ir/loweredIr/interpreter/intOperations.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/intOperations.kt index 3693dcfef8e..4425223a7db 100644 --- a/compiler/testData/ir/loweredIr/interpreter/intOperations.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/intOperations.kt @@ -1,3 +1,6 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR + const val minusOneVal = -1 const val oneVal = 1 const val twoVal = 2 @@ -97,14 +100,14 @@ fun box(): String { if (compareTo7 != 0) return "Fail 1.7" if (compareTo8 != 0) return "Fail 1.8" - if (plus1 != 3) return "Fail 2.1" - if (plus2 != 4) return "Fail 2.2" - if (plus3 != 5) return "Fail 2.3" - if (plus4 != 4) return "Fail 2.4" - if (plus5 != 4) return "Fail 2.5" - if (plus6 != 4) return "Fail 2.6" - if (plus7 != 4) return "Fail 2.7" - if (plus8 != 4) return "Fail 2.8" + if (plus1 != 3) return "Fail 2.1" + if (plus2 != 4) return "Fail 2.2" + if (plus3 != 5) return "Fail 2.3" + if (plus4 != 4) return "Fail 2.4" + if (plus5 != 4) return "Fail 2.5" + if (plus6 != 4) return "Fail 2.6" + if (plus7 != 4.0f) return "Fail 2.7" + if (plus8 != 4.0) return "Fail 2.8" if (minus1 != -1) return "Fail 3.1" if (minus2 != 0) return "Fail 3.2" diff --git a/compiler/testData/ir/loweredIr/interpreter/kCallableName.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/kCallableName.kt similarity index 91% rename from compiler/testData/ir/loweredIr/interpreter/kCallableName.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/kCallableName.kt index 2f507242e4c..253bfd78ed4 100644 --- a/compiler/testData/ir/loweredIr/interpreter/kCallableName.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/kCallableName.kt @@ -1,3 +1,6 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR + class A(val OK: Int, val somePropertyWithLongName: String) { fun foo() {} } diff --git a/compiler/testData/ir/loweredIr/interpreter/kt53272.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/kt53272.kt similarity index 71% rename from compiler/testData/ir/loweredIr/interpreter/kt53272.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/kt53272.kt index 3d2290c30ea..8b25912b429 100644 --- a/compiler/testData/ir/loweredIr/interpreter/kt53272.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/kt53272.kt @@ -1,3 +1,6 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR + // FILE: 1.kt const val name = E.OK.name diff --git a/compiler/testData/ir/loweredIr/interpreter/longOperations.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/longOperations.kt similarity index 93% rename from compiler/testData/ir/loweredIr/interpreter/longOperations.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/longOperations.kt index c9b80706cf7..1d10a176f60 100644 --- a/compiler/testData/ir/loweredIr/interpreter/longOperations.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/longOperations.kt @@ -1,3 +1,6 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR + const val minusOneVal = -1L const val oneVal = 1L const val twoVal = 2L @@ -97,14 +100,14 @@ fun box(): String { if (compareTo7 != 0) return "Fail 1.7" if (compareTo8 != 0) return "Fail 1.8" - if (plus1 != 3) return "Fail 2.1" - if (plus2 != 4) return "Fail 2.2" - if (plus3 != 5) return "Fail 2.3" - if (plus4 != 4) return "Fail 2.4" - if (plus5 != 4) return "Fail 2.5" - if (plus6 != 4) return "Fail 2.6" - if (plus7 != 4) return "Fail 2.7" - if (plus8 != 4) return "Fail 2.8" + if (plus1 != 3) return "Fail 2.1" + if (plus2 != 4) return "Fail 2.2" + if (plus3 != 5) return "Fail 2.3" + if (plus4 != 4) return "Fail 2.4" + if (plus5 != 4) return "Fail 2.5" + if (plus6 != 4) return "Fail 2.6" + if (plus7 != 4.0f) return "Fail 2.7" + if (plus8 != 4.0) return "Fail 2.8" if (minus1 != -1) return "Fail 3.1" if (minus2 != 0) return "Fail 3.2" diff --git a/compiler/testData/ir/loweredIr/interpreter/shortOperations.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/shortOperations.kt similarity index 93% rename from compiler/testData/ir/loweredIr/interpreter/shortOperations.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/shortOperations.kt index d8c037dab4b..fa77935c467 100644 --- a/compiler/testData/ir/loweredIr/interpreter/shortOperations.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/shortOperations.kt @@ -1,3 +1,6 @@ +// TARGET_BACKEND: JVM_IR +// IGNORE_BACKEND_K1: JVM_IR + const val minusOneVal = (-1).toShort() const val oneVal = 1.toShort() const val twoVal = 2.toShort() @@ -97,14 +100,14 @@ fun box(): String { if (compareTo7 != 0) return "Fail 1.7" if (compareTo8 != 0) return "Fail 1.8" - if (plus1 != 3) return "Fail 2.1" - if (plus2 != 4) return "Fail 2.2" - if (plus3 != 5) return "Fail 2.3" - if (plus4 != 4) return "Fail 2.4" - if (plus5 != 4) return "Fail 2.5" - if (plus6 != 4) return "Fail 2.6" - if (plus7 != 4) return "Fail 2.7" - if (plus8 != 4) return "Fail 2.8" + if (plus1 != 3) return "Fail 2.1" + if (plus2 != 4) return "Fail 2.2" + if (plus3 != 5) return "Fail 2.3" + if (plus4 != 4) return "Fail 2.4" + if (plus5 != 4) return "Fail 2.5" + if (plus6 != 4) return "Fail 2.6" + if (plus7 != 4.0f) return "Fail 2.7" + if (plus8 != 4.0) return "Fail 2.8" if (minus1 != -1) return "Fail 3.1" if (minus2 != 0) return "Fail 3.2" diff --git a/compiler/testData/ir/loweredIr/interpreter/stdlibConst.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/stdlibConst.kt similarity index 90% rename from compiler/testData/ir/loweredIr/interpreter/stdlibConst.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/stdlibConst.kt index 9126a067754..3d949cac206 100644 --- a/compiler/testData/ir/loweredIr/interpreter/stdlibConst.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/stdlibConst.kt @@ -1,3 +1,4 @@ +// TARGET_BACKEND: JVM_IR // WITH_STDLIB const val code = '1'.code diff --git a/compiler/testData/ir/loweredIr/interpreter/stringOperations.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/stringOperations.kt similarity index 98% rename from compiler/testData/ir/loweredIr/interpreter/stringOperations.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/stringOperations.kt index 471ca1b1bd9..027060f9a60 100644 --- a/compiler/testData/ir/loweredIr/interpreter/stringOperations.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/stringOperations.kt @@ -1,3 +1,5 @@ +// TARGET_BACKEND: JVM_IR + const val someStr = "123" const val otherStr = "other" diff --git a/compiler/testData/ir/loweredIr/interpreter/unsignedConst.kt b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/unsignedConst.kt similarity index 93% rename from compiler/testData/ir/loweredIr/interpreter/unsignedConst.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/unsignedConst.kt index 820abb98d2e..7029989fce2 100644 --- a/compiler/testData/ir/loweredIr/interpreter/unsignedConst.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/unsignedConst.kt @@ -1,4 +1,6 @@ +// TARGET_BACKEND: JVM_IR // WITH_STDLIB + const val byteVal: UByte = 1u const val shortVal: UShort = 2u const val intVal: UInt = 3u diff --git a/compiler/testData/codegen/box/constants/kt53480.kt b/compiler/testData/codegen/box/involvesIrInterpreter/kt53480.kt similarity index 100% rename from compiler/testData/codegen/box/constants/kt53480.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/kt53480.kt diff --git a/compiler/testData/codegen/box/annotations/kt55108.kt b/compiler/testData/codegen/box/involvesIrInterpreter/kt55108.kt similarity index 100% rename from compiler/testData/codegen/box/annotations/kt55108.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/kt55108.kt diff --git a/compiler/testData/codegen/box/evaluate/referenceNameFromStaticInDifferentModule.kt b/compiler/testData/codegen/box/involvesIrInterpreter/referenceNameFromStaticInDifferentModule.kt similarity index 100% rename from compiler/testData/codegen/box/evaluate/referenceNameFromStaticInDifferentModule.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/referenceNameFromStaticInDifferentModule.kt diff --git a/compiler/testData/codegen/box/evaluate/stringConcatenationWithObject.kt b/compiler/testData/codegen/box/involvesIrInterpreter/stringConcatenationWithObject.kt similarity index 100% rename from compiler/testData/codegen/box/evaluate/stringConcatenationWithObject.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/stringConcatenationWithObject.kt diff --git a/compiler/testData/codegen/box/evaluate/thisPlusString.kt b/compiler/testData/codegen/box/involvesIrInterpreter/thisPlusString.kt similarity index 100% rename from compiler/testData/codegen/box/evaluate/thisPlusString.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/thisPlusString.kt diff --git a/compiler/testData/ir/loweredIr/interpreter/useCorrectToString.kt b/compiler/testData/codegen/box/involvesIrInterpreter/useCorrectToString.kt similarity index 77% rename from compiler/testData/ir/loweredIr/interpreter/useCorrectToString.kt rename to compiler/testData/codegen/box/involvesIrInterpreter/useCorrectToString.kt index e1579b26634..e4e23c4559f 100644 --- a/compiler/testData/ir/loweredIr/interpreter/useCorrectToString.kt +++ b/compiler/testData/codegen/box/involvesIrInterpreter/useCorrectToString.kt @@ -1,3 +1,4 @@ +// TARGET_BACKEND: JVM_IR // This test is needed to check that IrCompileTimeChecker will not fail trying to find and analyze correct toString method object Obj { @@ -6,8 +7,6 @@ object Obj { fun Int.toString(): String = "Not OK" } -const val a = 1 // this is a dummy const to avoid check in IrInterpreterDumpHandler - fun box(): String { return "" + "$Obj" // force a call } diff --git a/compiler/tests-common-new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/BlackBoxCodegenTestGenerated.java b/compiler/tests-common-new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/BlackBoxCodegenTestGenerated.java index 306e5ab0985..fa6473bcf5e 100644 --- a/compiler/tests-common-new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/BlackBoxCodegenTestGenerated.java +++ b/compiler/tests-common-new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/BlackBoxCodegenTestGenerated.java @@ -27128,6 +27128,26 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest { } } + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter") + @TestDataPath("$PROJECT_ROOT") + public class InvolvesIrInterpreter { + @Test + public void testAllFilesPresentInInvolvesIrInterpreter() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true); + } + + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck") + @TestDataPath("$PROJECT_ROOT") + public class DumpIrAndCheck { + @Test + public void testAllFilesPresentInDumpIrAndCheck() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true); + } + } + } + @Nested @TestMetadata("compiler/testData/codegen/box/ir") @TestDataPath("$PROJECT_ROOT") diff --git a/compiler/tests-common-new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/IrBlackBoxCodegenTestGenerated.java b/compiler/tests-common-new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/IrBlackBoxCodegenTestGenerated.java index fbc4d13e716..740ba5061c9 100644 --- a/compiler/tests-common-new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/IrBlackBoxCodegenTestGenerated.java +++ b/compiler/tests-common-new/tests-gen/org/jetbrains/kotlin/test/runners/codegen/IrBlackBoxCodegenTestGenerated.java @@ -263,12 +263,6 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes runTest("compiler/testData/codegen/box/annotations/kt25489.kt"); } - @Test - @TestMetadata("kt55108.kt") - public void testKt55108() throws Exception { - runTest("compiler/testData/codegen/box/annotations/kt55108.kt"); - } - @Test @TestMetadata("mustBeDocumented.kt") public void testMustBeDocumented() throws Exception { @@ -8295,12 +8289,6 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes runTest("compiler/testData/codegen/box/constants/foldingBinaryOpsUnsignedConst.kt"); } - @Test - @TestMetadata("kt53480.kt") - public void testKt53480() throws Exception { - runTest("compiler/testData/codegen/box/constants/kt53480.kt"); - } - @Test @TestMetadata("kt9532.kt") public void testKt9532() throws Exception { @@ -17123,12 +17111,6 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes runTest("compiler/testData/codegen/box/evaluate/plus.kt"); } - @Test - @TestMetadata("referenceNameFromStaticInDifferentModule.kt") - public void testReferenceNameFromStaticInDifferentModule() throws Exception { - runTest("compiler/testData/codegen/box/evaluate/referenceNameFromStaticInDifferentModule.kt"); - } - @Test @TestMetadata("rem.kt") public void testRem() throws Exception { @@ -17141,18 +17123,6 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes runTest("compiler/testData/codegen/box/evaluate/simpleCallBinary.kt"); } - @Test - @TestMetadata("stringConcatenationWithObject.kt") - public void testStringConcatenationWithObject() throws Exception { - runTest("compiler/testData/codegen/box/evaluate/stringConcatenationWithObject.kt"); - } - - @Test - @TestMetadata("thisPlusString.kt") - public void testThisPlusString() throws Exception { - runTest("compiler/testData/codegen/box/evaluate/thisPlusString.kt"); - } - @Test @TestMetadata("unaryMinus.kt") public void testUnaryMinus() throws Exception { @@ -28106,6 +28076,170 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes } } + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter") + @TestDataPath("$PROJECT_ROOT") + public class InvolvesIrInterpreter { + @Test + public void testAllFilesPresentInInvolvesIrInterpreter() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true); + } + + @Test + @TestMetadata("kt53480.kt") + public void testKt53480() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/kt53480.kt"); + } + + @Test + @TestMetadata("kt55108.kt") + public void testKt55108() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/kt55108.kt"); + } + + @Test + @TestMetadata("referenceNameFromStaticInDifferentModule.kt") + public void testReferenceNameFromStaticInDifferentModule() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/referenceNameFromStaticInDifferentModule.kt"); + } + + @Test + @TestMetadata("stringConcatenationWithObject.kt") + public void testStringConcatenationWithObject() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/stringConcatenationWithObject.kt"); + } + + @Test + @TestMetadata("thisPlusString.kt") + public void testThisPlusString() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/thisPlusString.kt"); + } + + @Test + @TestMetadata("useCorrectToString.kt") + public void testUseCorrectToString() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/useCorrectToString.kt"); + } + + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck") + @TestDataPath("$PROJECT_ROOT") + public class DumpIrAndCheck { + @Test + public void testAllFilesPresentInDumpIrAndCheck() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true); + } + + @Test + @TestMetadata("booleanOperations.kt") + public void testBooleanOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/booleanOperations.kt"); + } + + @Test + @TestMetadata("byteOperations.kt") + public void testByteOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/byteOperations.kt"); + } + + @Test + @TestMetadata("charOperations.kt") + public void testCharOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/charOperations.kt"); + } + + @Test + @TestMetadata("constTrimIndent.kt") + public void testConstTrimIndent() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/constTrimIndent.kt"); + } + + @Test + @TestMetadata("constTrimMargin.kt") + public void testConstTrimMargin() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/constTrimMargin.kt"); + } + + @Test + @TestMetadata("doubleOperations.kt") + public void testDoubleOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/doubleOperations.kt"); + } + + @Test + @TestMetadata("enumName.kt") + public void testEnumName() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/enumName.kt"); + } + + @Test + @TestMetadata("enumRecursiveName.kt") + public void testEnumRecursiveName() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/enumRecursiveName.kt"); + } + + @Test + @TestMetadata("floatOperations.kt") + public void testFloatOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/floatOperations.kt"); + } + + @Test + @TestMetadata("ifConstVal.kt") + public void testIfConstVal() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/ifConstVal.kt"); + } + + @Test + @TestMetadata("intOperations.kt") + public void testIntOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/intOperations.kt"); + } + + @Test + @TestMetadata("kCallableName.kt") + public void testKCallableName() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/kCallableName.kt"); + } + + @Test + @TestMetadata("kt53272.kt") + public void testKt53272() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/kt53272.kt"); + } + + @Test + @TestMetadata("longOperations.kt") + public void testLongOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/longOperations.kt"); + } + + @Test + @TestMetadata("shortOperations.kt") + public void testShortOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/shortOperations.kt"); + } + + @Test + @TestMetadata("stdlibConst.kt") + public void testStdlibConst() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/stdlibConst.kt"); + } + + @Test + @TestMetadata("stringOperations.kt") + public void testStringOperations() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/stringOperations.kt"); + } + + @Test + @TestMetadata("unsignedConst.kt") + public void testUnsignedConst() throws Exception { + runTest("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck/unsignedConst.kt"); + } + } + } + @Nested @TestMetadata("compiler/testData/codegen/box/ir") @TestDataPath("$PROJECT_ROOT") diff --git a/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/backend/handlers/IrInterpreterDumpHandler.kt b/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/backend/handlers/IrInterpreterDumpHandler.kt index 25b00ff4618..2834cf6e747 100644 --- a/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/backend/handlers/IrInterpreterDumpHandler.kt +++ b/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/backend/handlers/IrInterpreterDumpHandler.kt @@ -5,7 +5,6 @@ package org.jetbrains.kotlin.test.backend.handlers -import org.jetbrains.kotlin.fir.descriptors.FirModuleDescriptor import org.jetbrains.kotlin.test.directives.CodegenTestDirectives import org.jetbrains.kotlin.test.model.BinaryArtifacts import org.jetbrains.kotlin.test.model.TestModule diff --git a/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractJvmBlackBoxCodegenTestBase.kt b/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractJvmBlackBoxCodegenTestBase.kt index c50fc680c52..f731f120847 100644 --- a/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractJvmBlackBoxCodegenTestBase.kt +++ b/compiler/tests-common-new/tests/org/jetbrains/kotlin/test/runners/codegen/AbstractJvmBlackBoxCodegenTestBase.kt @@ -5,6 +5,7 @@ package org.jetbrains.kotlin.test.runners.codegen +import org.jetbrains.kotlin.backend.jvm.lower.constEvaluationPhase import org.jetbrains.kotlin.config.JvmTarget import org.jetbrains.kotlin.test.Constructor import org.jetbrains.kotlin.test.TargetBackend @@ -12,19 +13,19 @@ import org.jetbrains.kotlin.test.TestJdkKind import org.jetbrains.kotlin.test.backend.BlackBoxCodegenSuppressor import org.jetbrains.kotlin.test.backend.handlers.BytecodeListingHandler import org.jetbrains.kotlin.test.backend.handlers.BytecodeTextHandler +import org.jetbrains.kotlin.test.backend.handlers.IrInterpreterDumpHandler import org.jetbrains.kotlin.test.bind import org.jetbrains.kotlin.test.builders.TestConfigurationBuilder import org.jetbrains.kotlin.test.builders.configureClassicFrontendHandlersStep import org.jetbrains.kotlin.test.builders.configureFirHandlersStep import org.jetbrains.kotlin.test.builders.configureJvmArtifactsHandlersStep +import org.jetbrains.kotlin.test.directives.CodegenTestDirectives import org.jetbrains.kotlin.test.directives.CodegenTestDirectives.IGNORE_DEXING import org.jetbrains.kotlin.test.directives.CodegenTestDirectives.USE_JAVAC_BASED_ON_JVM_TARGET import org.jetbrains.kotlin.test.directives.ConfigurationDirectives.WITH_STDLIB import org.jetbrains.kotlin.test.directives.DiagnosticsDirectives.DIAGNOSTICS import org.jetbrains.kotlin.test.directives.DiagnosticsDirectives.REPORT_ONLY_EXPLICITLY_DEFINED_DEBUG_INFO import org.jetbrains.kotlin.test.directives.ForeignAnnotationsDirectives -import org.jetbrains.kotlin.test.directives.JvmEnvironmentConfigurationDirectives -import org.jetbrains.kotlin.test.directives.JvmEnvironmentConfigurationDirectives.WITH_FOREIGN_ANNOTATIONS import org.jetbrains.kotlin.test.directives.JvmEnvironmentConfigurationDirectives.ENABLE_DEBUG_MODE import org.jetbrains.kotlin.test.directives.JvmEnvironmentConfigurationDirectives.JDK_KIND import org.jetbrains.kotlin.test.directives.JvmEnvironmentConfigurationDirectives.JVM_TARGET @@ -100,6 +101,15 @@ abstract class AbstractJvmBlackBoxCodegenTestBase( - FrontendKinds.FIR, - TargetBackend.JVM_IR -) { - override val frontendFacade: Constructor> - get() = ::FirFrontendFacade - - override val frontendToBackendConverter: Constructor> - get() = ::Fir2IrResultsConverter - - override val backendFacade: Constructor> - get() = ::JvmIrBackendFacade - - override fun configure(builder: TestConfigurationBuilder) { - super.configure(builder) - with(builder) { - useConfigurators( - ::CommonEnvironmentConfigurator, - ::JvmEnvironmentConfigurator - ) - - forTestsMatching("compiler/testData/ir/loweredIr/interpreter/*") { - defaultDirectives { - DUMP_IR_FOR_GIVEN_PHASES with constEvaluationPhase - } - } - - configureJvmArtifactsHandlersStep { - useHandlers(::IrInterpreterDumpHandler) - } - } - } -} \ No newline at end of file diff --git a/compiler/tests-common/tests/org/jetbrains/kotlin/codegen/AbstractLightAnalysisModeTest.kt b/compiler/tests-common/tests/org/jetbrains/kotlin/codegen/AbstractLightAnalysisModeTest.kt index b77577c8338..8e4e51c7ed4 100644 --- a/compiler/tests-common/tests/org/jetbrains/kotlin/codegen/AbstractLightAnalysisModeTest.kt +++ b/compiler/tests-common/tests/org/jetbrains/kotlin/codegen/AbstractLightAnalysisModeTest.kt @@ -29,7 +29,10 @@ abstract class AbstractLightAnalysisModeTest : CodegenTestCase() { override fun doMultiFileTest(wholeFile: File, files: List) { for (file in files) { - if (file.content.contains("// IGNORE_LIGHT_ANALYSIS") || file.content.contains("// MODULE:")) { + if (file.content.contains("// IGNORE_LIGHT_ANALYSIS") || + file.content.contains("// MODULE:") || + file.content.contains("// TARGET_FRONTEND: FIR") + ) { return } } diff --git a/compiler/tests-for-compiler-generator/tests/org/jetbrains/kotlin/test/generators/GenerateJUnit5CompilerTests.kt b/compiler/tests-for-compiler-generator/tests/org/jetbrains/kotlin/test/generators/GenerateJUnit5CompilerTests.kt index 7efae361868..2bd975437a6 100644 --- a/compiler/tests-for-compiler-generator/tests/org/jetbrains/kotlin/test/generators/GenerateJUnit5CompilerTests.kt +++ b/compiler/tests-for-compiler-generator/tests/org/jetbrains/kotlin/test/generators/GenerateJUnit5CompilerTests.kt @@ -13,7 +13,6 @@ import org.jetbrains.kotlin.test.runners.codegen.* import org.jetbrains.kotlin.test.runners.ir.AbstractFir2IrTextTest import org.jetbrains.kotlin.test.runners.ir.AbstractIrTextTest import org.jetbrains.kotlin.test.runners.ir.AbstractLightTreeFir2IrTextTest -import org.jetbrains.kotlin.test.runners.ir.AbstractLoweredIrInterpreterTest import org.jetbrains.kotlin.test.runners.ir.interpreter.AbstractJvmIrInterpreterAfterFir2IrTest import org.jetbrains.kotlin.test.runners.ir.interpreter.AbstractJvmIrInterpreterAfterPsi2IrTest import org.jetbrains.kotlin.test.utils.CUSTOM_TEST_DATA_EXTENSION_PATTERN @@ -266,10 +265,6 @@ fun generateJUnit5CompilerTests(args: Array) { model("debug/localVariables") } - testClass { - model("ir/loweredIr") - } - testClass { model("diagnostics/firTestWithJvmBackend") } diff --git a/compiler/tests-gen/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java b/compiler/tests-gen/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java index 8b5f3cb0e32..fc156633214 100644 --- a/compiler/tests-gen/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java +++ b/compiler/tests-gen/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java @@ -22870,6 +22870,32 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes } } + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class InvolvesIrInterpreter extends AbstractLightAnalysisModeTest { + private void runTest(String testDataFilePath) throws Exception { + KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM, testDataFilePath); + } + + public void testAllFilesPresentInInvolvesIrInterpreter() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true); + } + + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class DumpIrAndCheck extends AbstractLightAnalysisModeTest { + private void runTest(String testDataFilePath) throws Exception { + KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM, testDataFilePath); + } + + public void testAllFilesPresentInDumpIrAndCheck() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true); + } + } + } + @TestMetadata("compiler/testData/codegen/box/ir") @TestDataPath("$PROJECT_ROOT") @RunWith(JUnit3RunnerWithInners.class) diff --git a/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/JsCodegenBoxTestGenerated.java b/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/JsCodegenBoxTestGenerated.java index 0cba85dc22c..d2d83863a20 100644 --- a/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/JsCodegenBoxTestGenerated.java +++ b/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/JsCodegenBoxTestGenerated.java @@ -20968,6 +20968,26 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest { } } + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter") + @TestDataPath("$PROJECT_ROOT") + public class InvolvesIrInterpreter { + @Test + public void testAllFilesPresentInInvolvesIrInterpreter() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS, true); + } + + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck") + @TestDataPath("$PROJECT_ROOT") + public class DumpIrAndCheck { + @Test + public void testAllFilesPresentInDumpIrAndCheck() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS, true); + } + } + } + @Nested @TestMetadata("compiler/testData/codegen/box/ir") @TestDataPath("$PROJECT_ROOT") diff --git a/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/fir/FirJsCodegenBoxTestGenerated.java b/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/fir/FirJsCodegenBoxTestGenerated.java index 1d60840785d..6f9393990d7 100644 --- a/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/fir/FirJsCodegenBoxTestGenerated.java +++ b/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/fir/FirJsCodegenBoxTestGenerated.java @@ -20986,6 +20986,26 @@ public class FirJsCodegenBoxTestGenerated extends AbstractFirJsCodegenBoxTest { } } + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter") + @TestDataPath("$PROJECT_ROOT") + public class InvolvesIrInterpreter { + @Test + public void testAllFilesPresentInInvolvesIrInterpreter() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR, true); + } + + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck") + @TestDataPath("$PROJECT_ROOT") + public class DumpIrAndCheck { + @Test + public void testAllFilesPresentInDumpIrAndCheck() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR, true); + } + } + } + @Nested @TestMetadata("compiler/testData/codegen/box/ir") @TestDataPath("$PROJECT_ROOT") diff --git a/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/ir/IrJsCodegenBoxTestGenerated.java b/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/ir/IrJsCodegenBoxTestGenerated.java index d5d4a45fcff..5bd6a5dd424 100644 --- a/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/ir/IrJsCodegenBoxTestGenerated.java +++ b/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/ir/IrJsCodegenBoxTestGenerated.java @@ -20986,6 +20986,26 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest { } } + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter") + @TestDataPath("$PROJECT_ROOT") + public class InvolvesIrInterpreter { + @Test + public void testAllFilesPresentInInvolvesIrInterpreter() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR, true); + } + + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck") + @TestDataPath("$PROJECT_ROOT") + public class DumpIrAndCheck { + @Test + public void testAllFilesPresentInDumpIrAndCheck() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR, true); + } + } + } + @Nested @TestMetadata("compiler/testData/codegen/box/ir") @TestDataPath("$PROJECT_ROOT") diff --git a/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/ir/IrJsES6CodegenBoxTestGenerated.java b/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/ir/IrJsES6CodegenBoxTestGenerated.java index ac2bc7926ec..2749bf32aad 100644 --- a/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/ir/IrJsES6CodegenBoxTestGenerated.java +++ b/js/js.tests/tests-gen/org/jetbrains/kotlin/js/test/ir/IrJsES6CodegenBoxTestGenerated.java @@ -20986,6 +20986,26 @@ public class IrJsES6CodegenBoxTestGenerated extends AbstractIrJsES6CodegenBoxTes } } + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter") + @TestDataPath("$PROJECT_ROOT") + public class InvolvesIrInterpreter { + @Test + public void testAllFilesPresentInInvolvesIrInterpreter() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR_ES6, true); + } + + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck") + @TestDataPath("$PROJECT_ROOT") + public class DumpIrAndCheck { + @Test + public void testAllFilesPresentInDumpIrAndCheck() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR_ES6, true); + } + } + } + @Nested @TestMetadata("compiler/testData/codegen/box/ir") @TestDataPath("$PROJECT_ROOT") diff --git a/js/js.tests/tests-gen/org/jetbrains/kotlin/js/testOld/wasm/semantics/IrCodegenBoxWasmTestGenerated.java b/js/js.tests/tests-gen/org/jetbrains/kotlin/js/testOld/wasm/semantics/IrCodegenBoxWasmTestGenerated.java index ff5378228af..8919af75bce 100644 --- a/js/js.tests/tests-gen/org/jetbrains/kotlin/js/testOld/wasm/semantics/IrCodegenBoxWasmTestGenerated.java +++ b/js/js.tests/tests-gen/org/jetbrains/kotlin/js/testOld/wasm/semantics/IrCodegenBoxWasmTestGenerated.java @@ -18628,6 +18628,32 @@ public class IrCodegenBoxWasmTestGenerated extends AbstractIrCodegenBoxWasmTest } } + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class InvolvesIrInterpreter extends AbstractIrCodegenBoxWasmTest { + private void runTest(String testDataFilePath) throws Exception { + KotlinTestUtils.runTest0(this::doTest, TargetBackend.WASM, testDataFilePath); + } + + public void testAllFilesPresentInInvolvesIrInterpreter() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter"), Pattern.compile("^([^_](.+))\\.kt$"), null, TargetBackend.WASM, true); + } + + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class DumpIrAndCheck extends AbstractIrCodegenBoxWasmTest { + private void runTest(String testDataFilePath) throws Exception { + KotlinTestUtils.runTest0(this::doTest, TargetBackend.WASM, testDataFilePath); + } + + public void testAllFilesPresentInDumpIrAndCheck() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck"), Pattern.compile("^([^_](.+))\\.kt$"), null, TargetBackend.WASM, true); + } + } + } + @TestMetadata("compiler/testData/codegen/box/ir") @TestDataPath("$PROJECT_ROOT") @RunWith(JUnit3RunnerWithInners.class) diff --git a/native/native.tests/tests-gen/org/jetbrains/kotlin/konan/blackboxtest/K2NativeCodegenBoxTestGenerated.java b/native/native.tests/tests-gen/org/jetbrains/kotlin/konan/blackboxtest/K2NativeCodegenBoxTestGenerated.java index a02a7bc8b9a..da606b7fa74 100644 --- a/native/native.tests/tests-gen/org/jetbrains/kotlin/konan/blackboxtest/K2NativeCodegenBoxTestGenerated.java +++ b/native/native.tests/tests-gen/org/jetbrains/kotlin/konan/blackboxtest/K2NativeCodegenBoxTestGenerated.java @@ -23936,6 +23936,32 @@ public class K2NativeCodegenBoxTestGenerated extends AbstractNativeCodegenBoxTes } } + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter") + @TestDataPath("$PROJECT_ROOT") + @Tag("codegenK2") + @UseExtTestCaseGroupProvider() + @K2Pipeline() + public class InvolvesIrInterpreter { + @Test + public void testAllFilesPresentInInvolvesIrInterpreter() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true); + } + + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck") + @TestDataPath("$PROJECT_ROOT") + @Tag("codegenK2") + @UseExtTestCaseGroupProvider() + @K2Pipeline() + public class DumpIrAndCheck { + @Test + public void testAllFilesPresentInDumpIrAndCheck() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true); + } + } + } + @Nested @TestMetadata("compiler/testData/codegen/box/ir") @TestDataPath("$PROJECT_ROOT") diff --git a/native/native.tests/tests-gen/org/jetbrains/kotlin/konan/blackboxtest/NativeCodegenBoxTestGenerated.java b/native/native.tests/tests-gen/org/jetbrains/kotlin/konan/blackboxtest/NativeCodegenBoxTestGenerated.java index 534bc70e535..1e23ff3fcd0 100644 --- a/native/native.tests/tests-gen/org/jetbrains/kotlin/konan/blackboxtest/NativeCodegenBoxTestGenerated.java +++ b/native/native.tests/tests-gen/org/jetbrains/kotlin/konan/blackboxtest/NativeCodegenBoxTestGenerated.java @@ -23703,6 +23703,30 @@ public class NativeCodegenBoxTestGenerated extends AbstractNativeCodegenBoxTest } } + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter") + @TestDataPath("$PROJECT_ROOT") + @Tag("codegen") + @UseExtTestCaseGroupProvider() + public class InvolvesIrInterpreter { + @Test + public void testAllFilesPresentInInvolvesIrInterpreter() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true); + } + + @Nested + @TestMetadata("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck") + @TestDataPath("$PROJECT_ROOT") + @Tag("codegen") + @UseExtTestCaseGroupProvider() + public class DumpIrAndCheck { + @Test + public void testAllFilesPresentInDumpIrAndCheck() throws Exception { + KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/involvesIrInterpreter/dumpIrAndCheck"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true); + } + } + } + @Nested @TestMetadata("compiler/testData/codegen/box/ir") @TestDataPath("$PROJECT_ROOT")