Minor: kt21014.kt - add JVM_TARGET 1.8

This commit is contained in:
Dmitry Petrov
2020-12-23 10:55:16 +03:00
parent 10a5727260
commit 632f5af442
8 changed files with 56 additions and 0 deletions
@@ -2050,6 +2050,11 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT
runTest("compiler/testData/codegen/box/callableReference/javaField.kt");
}
@TestMetadata("kt21014.kt")
public void testKt21014() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt21014.kt");
}
@TestMetadata("kt37604.kt")
public void testKt37604() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt37604.kt");
@@ -0,0 +1,21 @@
// WITH_RUNTIME
// IGNORE_BACKEND: JVM
// IGNORE_LIGHT_ANALYSIS
// DONT_TARGET_EXACT_BACKEND: WASM
// WASM_MUTE_REASON: PROPERTY_REFERENCES
// JVM_TARGET: 1.8
// ^ This test causes SIGSEGV on JDK 1.6 with old back-end.
// Running it on JDK 1.6 (even with IGNORE_BACKEND: JVM) would still crash corresponding JVM process.
fun box(): String {
val ints = intArrayOf(1, 2, 3)
val test1 = IntArray::size.get(ints)
if (test1 != 3) throw Exception("IntArray::size.get(ints) != 3: $test1")
val test2 = with(ints, IntArray::size)
if (test2 != 3) throw Exception("with(ints, IntArray::size) != 3: $test2")
return "OK"
}
@@ -2050,6 +2050,11 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest {
runTest("compiler/testData/codegen/box/callableReference/javaField.kt");
}
@TestMetadata("kt21014.kt")
public void testKt21014() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt21014.kt");
}
@TestMetadata("kt37604.kt")
public void testKt37604() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt37604.kt");
@@ -2017,6 +2017,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public static class CallableReference extends AbstractLightAnalysisModeTest {
@TestMetadata("kt21014.kt")
public void ignoreKt21014() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt21014.kt");
}
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM, testDataFilePath);
}
@@ -2050,6 +2050,11 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes
runTest("compiler/testData/codegen/box/callableReference/javaField.kt");
}
@TestMetadata("kt21014.kt")
public void testKt21014() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt21014.kt");
}
@TestMetadata("kt37604.kt")
public void testKt37604() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt37604.kt");
@@ -1470,6 +1470,11 @@ public class IrJsCodegenBoxES6TestGenerated extends AbstractIrJsCodegenBoxES6Tes
runTest("compiler/testData/codegen/box/callableReference/genericLocalClassConstructorReference.kt");
}
@TestMetadata("kt21014.kt")
public void testKt21014() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt21014.kt");
}
@TestMetadata("kt37604.kt")
public void testKt37604() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt37604.kt");
@@ -1470,6 +1470,11 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
runTest("compiler/testData/codegen/box/callableReference/genericLocalClassConstructorReference.kt");
}
@TestMetadata("kt21014.kt")
public void testKt21014() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt21014.kt");
}
@TestMetadata("kt37604.kt")
public void testKt37604() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt37604.kt");
@@ -1470,6 +1470,11 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest {
runTest("compiler/testData/codegen/box/callableReference/genericLocalClassConstructorReference.kt");
}
@TestMetadata("kt21014.kt")
public void testKt21014() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt21014.kt");
}
@TestMetadata("kt37604.kt")
public void testKt37604() throws Exception {
runTest("compiler/testData/codegen/box/callableReference/kt37604.kt");