Expand default parameters conditions on inlining default function

#KT-14564 Fixed
 #KT-10848 Fixed
 #KT-12497 Fixed
This commit is contained in:
Mikhael Bogdanov
2017-04-26 16:08:47 +02:00
parent d49e9d7064
commit 02cc5f6bc1
16 changed files with 483 additions and 23 deletions
@@ -905,6 +905,18 @@ public class BlackBoxInlineCodegenTestGenerated extends AbstractBlackBoxInlineCo
doTest(fileName);
}
@TestMetadata("kt14564.kt")
public void testKt14564() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/boxInline/defaultValues/kt14564.kt");
doTest(fileName);
}
@TestMetadata("kt14564_2.kt")
public void testKt14564_2() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/boxInline/defaultValues/kt14564_2.kt");
doTest(fileName);
}
@TestMetadata("kt5685.kt")
public void testKt5685() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/boxInline/defaultValues/kt5685.kt");
@@ -916,6 +928,33 @@ public class BlackBoxInlineCodegenTestGenerated extends AbstractBlackBoxInlineCo
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/boxInline/defaultValues/simpleDefaultMethod.kt");
doTest(fileName);
}
@TestMetadata("compiler/testData/codegen/boxInline/defaultValues/maskElumination")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public static class MaskElumination extends AbstractBlackBoxInlineCodegenTest {
@TestMetadata("32Parameters.kt")
public void test32Parameters() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/boxInline/defaultValues/maskElumination/32Parameters.kt");
doTest(fileName);
}
@TestMetadata("33Parameters.kt")
public void test33Parameters() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/boxInline/defaultValues/maskElumination/33Parameters.kt");
doTest(fileName);
}
public void testAllFilesPresentInMaskElumination() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/codegen/boxInline/defaultValues/maskElumination"), Pattern.compile("^(.+)\\.kt$"), TargetBackend.ANY, true);
}
@TestMetadata("simple.kt")
public void testSimple() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/boxInline/defaultValues/maskElumination/simple.kt");
doTest(fileName);
}
}
}
@TestMetadata("compiler/testData/codegen/boxInline/delegatedProperty")