JVM_IR indy-lambdas: initial implementation and tests
KT-44278 KT-26060 KT-42621
This commit is contained in:
committed by
TeamCityServer
parent
0bc386cb08
commit
d94912ed62
+144
@@ -16179,6 +16179,145 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/invokedynamic"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true);
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/invokedynamic/lambdas")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class Lambdas extends AbstractLightAnalysisModeTest {
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM, testDataFilePath);
|
||||
}
|
||||
|
||||
public void testAllFilesPresentInLambdas() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/invokedynamic/lambdas"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true);
|
||||
}
|
||||
|
||||
@TestMetadata("capturedDispatchReceiver.kt")
|
||||
public void testCapturedDispatchReceiver() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/capturedDispatchReceiver.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("capturedExtensionReceiver.kt")
|
||||
public void testCapturedExtensionReceiver() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/capturedExtensionReceiver.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("capturingValue.kt")
|
||||
public void testCapturingValue() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/capturingValue.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("capturingVar.kt")
|
||||
public void testCapturingVar() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/capturingVar.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("extensionLambda.kt")
|
||||
public void testExtensionLambda() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/extensionLambda.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("nestedIndyLambdas.kt")
|
||||
public void testNestedIndyLambdas() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/nestedIndyLambdas.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("primitiveValueParameters.kt")
|
||||
public void testPrimitiveValueParameters() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/primitiveValueParameters.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("simpleIndyLambda.kt")
|
||||
public void testSimpleIndyLambda() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/simpleIndyLambda.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("suspendLambda.kt")
|
||||
public void testSuspendLambda() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/suspendLambda.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("voidReturnType.kt")
|
||||
public void testVoidReturnType() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/voidReturnType.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/invokedynamic/lambdas/inline")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class Inline extends AbstractLightAnalysisModeTest {
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM, testDataFilePath);
|
||||
}
|
||||
|
||||
public void testAllFilesPresentInInline() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/invokedynamic/lambdas/inline"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true);
|
||||
}
|
||||
|
||||
@TestMetadata("crossinlineLambda1.kt")
|
||||
public void testCrossinlineLambda1() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/inline/crossinlineLambda1.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("crossinlineLambda2.kt")
|
||||
public void testCrossinlineLambda2() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/inline/crossinlineLambda2.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("inlineFunInDifferentPackage.kt")
|
||||
public void testInlineFunInDifferentPackage() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/inline/inlineFunInDifferentPackage.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("inlineLambda1.kt")
|
||||
public void testInlineLambda1() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/inline/inlineLambda1.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/invokedynamic/lambdas/inlineClassInSignature")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class InlineClassInSignature extends AbstractLightAnalysisModeTest {
|
||||
@TestMetadata("lambdaWithInlineInt.kt")
|
||||
public void ignoreLambdaWithInlineInt() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/inlineClassInSignature/lambdaWithInlineInt.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("lambdaWithInlineNAny.kt")
|
||||
public void ignoreLambdaWithInlineNAny() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/inlineClassInSignature/lambdaWithInlineNAny.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("lambdaWithInlineNInt.kt")
|
||||
public void ignoreLambdaWithInlineNInt() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/inlineClassInSignature/lambdaWithInlineNInt.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("lambdaWithInlineNString.kt")
|
||||
public void ignoreLambdaWithInlineNString() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/inlineClassInSignature/lambdaWithInlineNString.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("lambdaWithInlineString.kt")
|
||||
public void ignoreLambdaWithInlineString() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/inlineClassInSignature/lambdaWithInlineString.kt");
|
||||
}
|
||||
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM, testDataFilePath);
|
||||
}
|
||||
|
||||
public void testAllFilesPresentInInlineClassInSignature() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/invokedynamic/lambdas/inlineClassInSignature"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM, true);
|
||||
}
|
||||
|
||||
@TestMetadata("lambdaWithInlineAny.kt")
|
||||
public void testLambdaWithInlineAny() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/lambdas/inlineClassInSignature/lambdaWithInlineAny.kt");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/invokedynamic/sam")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
@@ -16296,6 +16435,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/sam/unboundFunctionReferenceEquality.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("voidReturnTypeAsGeneric.kt")
|
||||
public void testVoidReturnTypeAsGeneric() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/invokedynamic/sam/voidReturnTypeAsGeneric.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/invokedynamic/sam/inline")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
|
||||
Reference in New Issue
Block a user