Update tests

This commit is contained in:
Roman Artemev
2018-08-02 19:48:23 +03:00
committed by romanart
parent e6b8ade096
commit 8a871b3f0c
70 changed files with 19 additions and 58 deletions
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JS_IR
fun Array<String>.test1(): Array<String> {
val func = { i:Int -> this}
return func(1)
+1
View File
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JS_IR
class IntRange {
operator fun contains(a: Int) = (1..2).contains(a)
}
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
// TODO: Enable for JS when it supports Java class library.
// IGNORE_BACKEND: JS, NATIVE
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
class Outer() {
val s = "xyzzy"
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
open class Base(val fn: () -> String)
fun box(): String {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
open class Base(val fn: () -> String)
fun box(): String {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
open class Foo(val x: () -> String)
class Outer {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
interface Test {
fun test(): String
}
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
open class Base(val fn: () -> String)
fun box(): String {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
abstract class Base(val fn: () -> String)
class Outer {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
open class Base(val callback: () -> String)
class Outer {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
open class Base(val callback: () -> String)
class Outer {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
open class Base(val callback: () -> String)
class Outer {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
open class Base(val callback: () -> String)
class Outer {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
open class Foo(val x: () -> String)
open class Foo2(val foo: Foo)
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
open class Base(val callback: () -> String)
class Outer {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
interface Callback {
fun invoke(): String
}
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
interface Callback {
fun invoke(): String
}
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
interface Callback {
fun invoke(): String
}
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JVM_IR
open class JClass() {
fun test(): String {
return "OK"
@@ -1,4 +1,4 @@
// IGNORE_BACKEND: JS_IR, JVM_IR
// IGNORE_BACKEND: JVM_IR
// WITH_COROUTINES
// COMMON_COROUTINES_TEST
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JS_IR
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS
// COMMON_COROUTINES_TEST
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JS_IR
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS
// COMMON_COROUTINES_TEST
@@ -1,5 +1,5 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
// IGNORE_BACKEND: JVM_IR
// DONT_RUN_GENERATED_CODE: JS
tailrec fun test(x : Int = 0, e : Any = "a") {
@@ -1,5 +1,3 @@
// IGNORE_BACKEND: NATIVE
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
var result = ""
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
// KT-4423 Enum with function not compiled
enum class Sign(val str: String, val func: (x: Int, y: Int) -> Int){
-1
View File
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
enum class Foo(
val x: String,
val callback: () -> String
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JS_IR
interface Callback {
fun invoke(): String
}
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JS_IR
fun Int.thisRef1() = fun () = this
fun Int.thisRef2() = fun (): Int {return this}
@@ -1,6 +1,4 @@
// !LANGUAGE: +ProperIeee754Comparisons
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
fun testF(x: Any) =
when (x) {
@@ -1,5 +1,5 @@
// !LANGUAGE: +InlineClasses
// IGNORE_BACKEND: JVM_IR, JS_IR
// IGNORE_BACKEND: JVM_IR
inline class SuccessOrFailure<T>(val a: Any?) {
fun getOrThrow(): T = a as T
@@ -1,5 +1,3 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
fun box(): String {
abstract class L1 {
abstract fun foo(): String
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
fun String.bar(): String {
open class Local {
fun result() = this@bar
-1
View File
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
fun box(): String {
val s = "captured";
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JVM_IR
class A {
var a: String = "Fail"
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
// IGNORE_BACKEND: JS
@@ -1,4 +1,5 @@
// !LANGUAGE: +MultiPlatformProjects
// IGNORE_BACKEND: JS_IR
// IGNORE_BACKEND: JVM_IR
// WITH_RUNTIME
// FILE: common.kt
@@ -1,4 +1,5 @@
// !LANGUAGE: +MultiPlatformProjects
// IGNORE_BACKEND: JS_IR
// IGNORE_BACKEND: JVM_IR
// WITH_RUNTIME
// FILE: common.kt
@@ -1,4 +1,5 @@
// !LANGUAGE: +MultiPlatformProjects
// IGNORE_BACKEND: JS_IR
// IGNORE_BACKEND: JVM_IR
// WITH_RUNTIME
// FILE: common.kt
@@ -1,4 +1,5 @@
// !LANGUAGE: +MultiPlatformProjects
// IGNORE_BACKEND: JS_IR
// WITH_RUNTIME
// IGNORE_BACKEND: JVM_IR
// FILE: common.kt
@@ -1,4 +1,5 @@
// !LANGUAGE: +MultiPlatformProjects
// IGNORE_BACKEND: JS_IR
// WITH_RUNTIME
// IGNORE_BACKEND: JVM_IR
// FILE: common.kt
@@ -1,4 +1,5 @@
// !LANGUAGE: +MultiPlatformProjects
// IGNORE_BACKEND: JS_IR
// WITH_RUNTIME
// IGNORE_BACKEND: JVM_IR
// FILE: common.kt
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JVM_IR
class A(val value: String)
fun A.test(): String {
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JVM_IR
// FILE: Outer.kt
package another
-1
View File
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
interface A {
// There must be no delegation methods for 'log' and 'bar' in C as they are private
private val log: String get() = "O"
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
class Outer {
val outerProp: String
constructor(x: String) {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
class Outer {
val outerProp: String
constructor(x: String) {
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JS_IR
fun box(): String {
String()
return String() + "OK" + String()
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JVM_IR
fun box(): String {
A.Nested().nestedA()
A.Nested().Inner().innerA()
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
interface Z {
fun testFun() : String {
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
interface Z {
fun testFun(): String {
@@ -1,6 +1,4 @@
// !LANGUAGE: +VariableDeclarationInWhenSubject +ProperIeee754Comparisons
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
val az: Any = -0.0
val afz: Any = -0.0f
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
// FILE: 1.kt
// LANGUAGE_VERSION: 1.2
// SKIP_INLINE_CHECK_IN: inlineFun$default
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
// NO_CHECK_LAMBDA_INLINING
// FILE: 1.kt
package test
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
// NO_CHECK_LAMBDA_INLINING
// FILE: 1.kt
package test
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
// FILE: 1.kt
// LANGUAGE_VERSION: 1.2
// SKIP_INLINE_CHECK_IN: inlineFun$default
@@ -1,5 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JS_IR
// FILE: 1.kt
// LANGUAGE_VERSION: 1.2
// SKIP_INLINE_CHECK_IN: inlineFun$default
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JS_IR
// FILE: 1.kt
package test