K2: Support callable references adaptation on top-level

^KT-45989 In progress
^KT-54709 Related
^KT-55217 Fixed
This commit is contained in:
Denis.Zharkov
2022-11-25 12:28:18 +01:00
committed by Space Team
parent 8f8ea8c57f
commit dcdc48a233
13 changed files with 118 additions and 31 deletions
@@ -3102,6 +3102,22 @@ public class DiagnosisCompilerTestFE10TestdataTestGenerated extends AbstractDiag
runTest("compiler/testData/diagnostics/tests/callableReference/withQuestionMarks.kt");
}
@Nested
@TestMetadata("compiler/testData/diagnostics/tests/callableReference/adapted")
@TestDataPath("$PROJECT_ROOT")
public class Adapted {
@Test
public void testAllFilesPresentInAdapted() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/tests/callableReference/adapted"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.fir\\.kts?$"), true);
}
@Test
@TestMetadata("simpleAdaptationOutsideOfCall.kt")
public void testSimpleAdaptationOutsideOfCall() throws Exception {
runTest("compiler/testData/diagnostics/tests/callableReference/adapted/simpleAdaptationOutsideOfCall.kt");
}
}
@Nested
@TestMetadata("compiler/testData/diagnostics/tests/callableReference/bound")
@TestDataPath("$PROJECT_ROOT")