Support non-reified type parameters in typeOf in JVM and JVM_IR
#KT-30279 Fixed
This commit is contained in:
committed by
Alexander Udalov
parent
6fb40878c4
commit
0ce16b9d8c
Generated
+76
@@ -20947,6 +20947,82 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
|
||||
public void testAllFilesPresentInNoReflect() throws Exception {
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/reflection/typeOf/noReflect"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR, true);
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/reflection/typeOf/noReflect/nonReifiedTypeParameters")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class NonReifiedTypeParameters extends AbstractIrJsCodegenBoxTest {
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest0(this::doTest, TargetBackend.JS_IR, testDataFilePath);
|
||||
}
|
||||
|
||||
public void testAllFilesPresentInNonReifiedTypeParameters() throws Exception {
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/reflection/typeOf/noReflect/nonReifiedTypeParameters"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class NonReifiedTypeParameters extends AbstractIrJsCodegenBoxTest {
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest0(this::doTest, TargetBackend.JS_IR, testDataFilePath);
|
||||
}
|
||||
|
||||
public void testAllFilesPresentInNonReifiedTypeParameters() throws Exception {
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR, true);
|
||||
}
|
||||
|
||||
@TestMetadata("defaultUpperBound.kt")
|
||||
public void testDefaultUpperBound() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/defaultUpperBound.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("equalsOnClassParameters.kt")
|
||||
public void testEqualsOnClassParameters() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/equalsOnClassParameters.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("equalsOnFunctionParameters.kt")
|
||||
public void testEqualsOnFunctionParameters() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/equalsOnFunctionParameters.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("innerGeneric.kt")
|
||||
public void testInnerGeneric() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/innerGeneric.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("simpleClassParameter.kt")
|
||||
public void testSimpleClassParameter() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/simpleClassParameter.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("simpleFunctionParameter.kt")
|
||||
public void testSimpleFunctionParameter() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/simpleFunctionParameter.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("simplePropertyParameter.kt")
|
||||
public void testSimplePropertyParameter() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/simplePropertyParameter.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("typeParameterFlags.kt")
|
||||
public void testTypeParameterFlags() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/typeParameterFlags.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("upperBoundUsesOuterClassParameter.kt")
|
||||
public void testUpperBoundUsesOuterClassParameter() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/upperBoundUsesOuterClassParameter.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("upperBounds.kt")
|
||||
public void testUpperBounds() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/upperBounds.kt");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+76
@@ -21007,6 +21007,82 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest {
|
||||
public void testAllFilesPresentInNoReflect() throws Exception {
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/reflection/typeOf/noReflect"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS, true);
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/reflection/typeOf/noReflect/nonReifiedTypeParameters")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class NonReifiedTypeParameters extends AbstractJsCodegenBoxTest {
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest0(this::doTest, TargetBackend.JS, testDataFilePath);
|
||||
}
|
||||
|
||||
public void testAllFilesPresentInNonReifiedTypeParameters() throws Exception {
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/reflection/typeOf/noReflect/nonReifiedTypeParameters"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class NonReifiedTypeParameters extends AbstractJsCodegenBoxTest {
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest0(this::doTest, TargetBackend.JS, testDataFilePath);
|
||||
}
|
||||
|
||||
public void testAllFilesPresentInNonReifiedTypeParameters() throws Exception {
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS, true);
|
||||
}
|
||||
|
||||
@TestMetadata("defaultUpperBound.kt")
|
||||
public void testDefaultUpperBound() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/defaultUpperBound.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("equalsOnClassParameters.kt")
|
||||
public void testEqualsOnClassParameters() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/equalsOnClassParameters.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("equalsOnFunctionParameters.kt")
|
||||
public void testEqualsOnFunctionParameters() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/equalsOnFunctionParameters.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("innerGeneric.kt")
|
||||
public void testInnerGeneric() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/innerGeneric.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("simpleClassParameter.kt")
|
||||
public void testSimpleClassParameter() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/simpleClassParameter.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("simpleFunctionParameter.kt")
|
||||
public void testSimpleFunctionParameter() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/simpleFunctionParameter.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("simplePropertyParameter.kt")
|
||||
public void testSimplePropertyParameter() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/simplePropertyParameter.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("typeParameterFlags.kt")
|
||||
public void testTypeParameterFlags() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/typeParameterFlags.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("upperBoundUsesOuterClassParameter.kt")
|
||||
public void testUpperBoundUsesOuterClassParameter() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/upperBoundUsesOuterClassParameter.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("upperBounds.kt")
|
||||
public void testUpperBounds() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/reflection/typeOf/nonReifiedTypeParameters/upperBounds.kt");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user