[test] Mute failing irText tests

This commit is contained in:
Sergej Jaskiewicz
2023-03-13 16:27:27 +01:00
committed by Space Team
parent 7dba138da6
commit b57f436a44
106 changed files with 279 additions and 135 deletions
@@ -1,3 +1,6 @@
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
annotation class TestAnn(val x: String)
@TestAnn("class")
@@ -18,4 +21,4 @@ class Host {
enum class TestEnum
@TestAnn("annotation")
annotation class TestAnnotation
annotation class TestAnnotation
@@ -1,7 +1,10 @@
// FIR_IDENTICAL
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
const val ONE = 1
annotation class A(val x: Int)
@A(ONE) fun test1() {}
@A(1+1) fun test2() {}
@A(1+1) fun test2() {}
@@ -1,7 +1,9 @@
// FIR_IDENTICAL
// WITH_STDLIB
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
annotation class Ann
@delegate:Ann
val test1 by lazy { 42 }
val test1 by lazy { 42 }
@@ -1,3 +1,6 @@
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
annotation class TestAnn(val x: String)
enum class TestEnum {
@@ -5,4 +8,4 @@ enum class TestEnum {
@TestAnn("ENTRY2") ENTRY2 {
val x = 42
}
}
}
@@ -1,6 +1,9 @@
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
enum class En { A, B, C, D }
annotation class TestAnn(val x: En)
@TestAnn(En.A)
fun test1() {}
fun test1() {}
@@ -1,8 +1,10 @@
// WITH_STDLIB
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
annotation class A(val x: String)
fun foo(m: Map<String, Int>) {
@A("foo/test")
val test by lazy { 42 }
}
}
@@ -1,4 +1,6 @@
// WITH_STDLIB
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
class C {
val test1 = 0
@@ -18,4 +20,4 @@ class C {
val test7 by lazy { 42 }
var test8 by hashMapOf<String, Int>()
}
}
@@ -1,4 +1,7 @@
// FIR_IDENTICAL
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
const val I0 = 0
const val I1 = 1
const val I2 = I0 + I1 + I1
@@ -1,5 +1,7 @@
// FIR_IDENTICAL
// !LANGUAGE: +ContextReceivers
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
class Outer {
val x: Int = 1
@@ -1,5 +1,7 @@
// FIR_IDENTICAL
// !LANGUAGE: +ContextReceivers
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
class O(val o: String)
@@ -1,5 +1,7 @@
// FIR_IDENTICAL
// !LANGUAGE: +ContextReceivers
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
class C {
val c = 42
@@ -1,4 +1,6 @@
// !LANGUAGE: +ContextReceivers
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
class Param
class C {
@@ -1,5 +1,7 @@
// FIR_IDENTICAL
// !LANGUAGE: +ContextReceivers
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
interface Lazy<T>
@@ -1,5 +1,7 @@
// FIR_IDENTICAL
// !LANGUAGE: +ContextReceivers
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
class Context
@@ -1,5 +1,7 @@
// FIR_IDENTICAL
// !LANGUAGE: +ContextReceivers
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
context(Int, String)
fun foo(): Int {
@@ -1,6 +1,8 @@
// FIR_IDENTICAL
// !LANGUAGE: +ContextReceivers
// !DIAGNOSTICS: -UNUSED_PARAMETER
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
interface NumberOperations {
fun Number.plus(other: Number): Number
@@ -13,4 +15,4 @@ context(NumberOperations) fun Matrix.plus(other: Matrix): Matrix = TODO()
fun NumberOperations.plusMatrix(m1: Matrix, m2: Matrix) {
m1.plus(m2)
m2.plus(m1)
}
}
@@ -1,5 +1,7 @@
// FIR_IDENTICAL
// !LANGUAGE: +ContextReceivers
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
context(T)
fun <T> useContext(block: (T) -> Unit) { }
@@ -1,4 +1,6 @@
// WITH_STDLIB
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
val test1 by lazy { 42 }
@@ -7,4 +9,4 @@ class C(val map: MutableMap<String, Any>) {
var test3 by map
}
var test4 by hashMapOf<String, Any>()
var test4 by hashMapOf<String, Any>()
+4 -1
View File
@@ -1,6 +1,9 @@
// FIR_IDENTICAL
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
suspend fun foo() = baz<Unit>()
suspend fun bar() = baz<Any>()
suspend fun <T> baz(): T {
TODO()
}
}
+2
View File
@@ -1,5 +1,7 @@
// ISSUE: KT-47527
// WITH_STDLIB
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
fun test_1(value: Any?): String? = value?.let { return "O" }
fun test_2(value: Any?): String? = run {
+2
View File
@@ -1,4 +1,6 @@
// ISSUE: KT-52677
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
@Target(AnnotationTarget.TYPE)
annotation class MySerializable(val c: kotlin.reflect.KClass<*>)
@@ -1,4 +1,6 @@
// WITH_STDLIB
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
fun test1() {
val x by lazy { 42 }
@@ -10,4 +12,4 @@ fun test2() {
x = 0
x++
x += 1
}
}
@@ -1,4 +1,6 @@
// IGNORE_BACKEND_K2: JVM_IR
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
// !LANGUAGE: +MultiPlatformProjects
expect abstract class A protected constructor() {
@@ -1,6 +1,8 @@
// FIR_IDENTICAL
// !LANGUAGE: +MultiPlatformProjects
// IGNORE_BACKEND_K1: ANY
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
// MODULE: lib
// FILE: lib.kt
@@ -15,4 +17,4 @@ actual enum class MyEnum {
FOO,
BAR,
BAZ
}
}
@@ -1,8 +1,10 @@
// IGNORE_BACKEND_K2: JVM_IR
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
// !LANGUAGE: +MultiPlatformProjects
expect sealed class Ops()
expect class Add() : Ops
actual sealed class Ops actual constructor()
actual class Add actual constructor() : Ops()
actual class Add actual constructor() : Ops()
@@ -1,4 +1,6 @@
// WITH_STDLIB
// IGNORE_BACKEND_K2: JS_IR
// IGNORE_BACKEND_K2: JS_IR_ES6
val test1 = 0