[K/N] Implement a concept of conditional ignore of K/N blackbox tests
^KT-59288 Fixed
This commit is contained in:
committed by
Space Team
parent
6ce33e80a5
commit
c38a0e10af
+2
-1
@@ -1,6 +1,7 @@
|
||||
// Fails on native when run with `-Pkotlin.internal.native.test.cacheMode=STATIC_EVERYWHERE`.
|
||||
// Looks like the call to `k` fails as `k` is not exported from the lib module.
|
||||
// IGNORE_BACKEND: NATIVE
|
||||
// IGNORE_NATIVE: cacheMode=STATIC_EVERYWHERE
|
||||
// IGNORE_NATIVE: cacheMode=STATIC_PER_FILE_EVERYWHERE
|
||||
// MODULE: lib
|
||||
// FILE: Z.kt
|
||||
package z
|
||||
|
||||
-2
@@ -1,7 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// ISSUE: KT-55318
|
||||
// KT-55486: native linker error with `-Pkotlin.internal.native.test.cacheMode=STATIC_EVERYWHERE`
|
||||
// IGNORE_BACKEND_K2: NATIVE
|
||||
|
||||
// MODULE: lib
|
||||
// FILE: lib.kt
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// WITH_STDLIB
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
expect class A {
|
||||
|
||||
Vendored
+1
-1
@@ -1,5 +1,5 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// ISSUE: KT-57963
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,7 +1,8 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// WITH_STDLIB
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// JS tests don't support MPP modules compilation
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// ISSUE: KT-58252
|
||||
|
||||
// MODULE: lib-common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: lib
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// ISSUE: KT-58003
|
||||
|
||||
|
||||
Vendored
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// ISSUE: KT-58004
|
||||
|
||||
|
||||
compiler/testData/codegen/box/multiplatform/k2/basic/expectActualFakeOverridesWithTypeParameters2.kt
Vendored
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// ISSUE: KT-58124
|
||||
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common0
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// IGNORE_BACKEND: JVM, JVM_IR
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// Ignore until KT-62926 is fixed
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
// TARGET_BACKEND: JVM_IR
|
||||
// TARGET_BACKEND: NATIVE
|
||||
|
||||
// IGNORE_BACKEND_K1: NATIVE
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects +ImplicitSignedToUnsignedIntegerConversion
|
||||
// WITH_STDLIB
|
||||
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// ISSUE: KT-58896
|
||||
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_CODEGEN_WITH_IR_FAKE_OVERRIDE_GENERATION: KT-62535
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
// IGNORE_CODEGEN_WITH_IR_FAKE_OVERRIDE_GENERATION: KT-62535
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common1
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// ISSUE: KT-58229
|
||||
// WITH_STDLIB
|
||||
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// ISSUE: KT-60850
|
||||
// WITH_STDLIB
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// ISSUE: KT-56329
|
||||
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// ISSUE: KT-58229
|
||||
// WITH_STDLIB
|
||||
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// ISSUE: KT-60850
|
||||
// WITH_STDLIB
|
||||
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// ISSUE: KT-58229
|
||||
// WITH_STDLIB
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// ISSUE: KT-58229
|
||||
// WITH_STDLIB
|
||||
|
||||
|
||||
compiler/testData/codegen/box/multiplatform/k2/complexMatchings/expectCtorlessFinalToActualObject.kt
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
+2
-1
@@ -1,6 +1,7 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// ISSUE: KT-61972
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM, NATIVE
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
data class CommonData(val value: String)
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// ISSUE: KT-62671
|
||||
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// ISSUE: KT-57181
|
||||
// WASM_MUTE_REASON: EXPECT_DEFAULT_PARAMETERS
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
|
||||
Vendored
+2
-1
@@ -1,4 +1,5 @@
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// ISSUE: KT-57263
|
||||
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
|
||||
// MODULE: common
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
|
||||
// MODULE: common
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
|
||||
// MODULE: common
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
|
||||
// MODULE: common
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
|
||||
// MODULE: common
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
|
||||
// MODULE: common
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
|
||||
// MODULE: common
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
Vendored
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
// WITH_COROUTINES
|
||||
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
// !LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, NATIVE, WASM
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// WITH_STDLIB
|
||||
|
||||
// MODULE: common
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// It accidentially passes K1 JVM while not intended to do so.
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM, NATIVE
|
||||
// IGNORE_BACKEND_K1: JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
|
||||
@@ -4,7 +4,8 @@
|
||||
// TARGET_BACKEND: WASM
|
||||
// TARGET_BACKEND: JVM_IR
|
||||
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
@@ -4,7 +4,8 @@
|
||||
// TARGET_BACKEND: WASM
|
||||
// TARGET_BACKEND: JVM_IR
|
||||
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
+2
-1
@@ -4,7 +4,8 @@
|
||||
// TARGET_BACKEND: WASM
|
||||
// TARGET_BACKEND: JVM_IR
|
||||
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// IllegalArgumentException: arg wrongly != this@Test5: arg=null, this@Test5=[object Object]
|
||||
// IGNORE_BACKEND_K2: JS_IR, JS_IR_ES6
|
||||
|
||||
Vendored
+2
-1
@@ -5,7 +5,8 @@
|
||||
// TARGET_BACKEND: WASM
|
||||
// TARGET_BACKEND: JVM_IR
|
||||
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
|
||||
// MODULE: common
|
||||
// FILE: common.kt
|
||||
|
||||
+2
-1
@@ -1,5 +1,6 @@
|
||||
// LANGUAGE: +MultiPlatformProjects
|
||||
// IGNORE_BACKEND_K1: ANY
|
||||
// IGNORE_BACKEND_K1: JVM, JVM_IR, JS, JS_IR, JS_IR_ES6, WASM
|
||||
// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE
|
||||
// IGNORE_REASON: multimodule MPP tests are not supported in K1
|
||||
// ISSUE: KT-59613
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
// https://youtrack.jetbrains.com/issue/KT-50289/EXCBADACCESS-getting-non-null-property-in-safe-call-chain
|
||||
// IGNORE_BACKEND: NATIVE
|
||||
// IGNORE_NATIVE: optimizationMode=DEBUG
|
||||
// IGNORE_NATIVE: optimizationMode=NO
|
||||
|
||||
abstract class Z {
|
||||
init {
|
||||
|
||||
+4
-1
@@ -1,4 +1,7 @@
|
||||
// IGNORE_BACKEND: NATIVE
|
||||
// IGNORE_NATIVE: cacheMode=NO
|
||||
// IGNORE_NATIVE: cacheMode=STATIC_ONLY_DIST
|
||||
// IGNORE_NATIVE: cacheMode=STATIC_EVERYWHERE && target=linux_x64
|
||||
// IGNORE_NATIVE: cacheMode=STATIC_PER_FILE_EVERYWHERE && target=linux_x64
|
||||
// IGNORE_BACKEND: JS_IR, JS_IR_ES6
|
||||
// IGNORE_BACKEND: WASM
|
||||
// MODULE: lib
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// The test isn't passing when using K/N per-file caches and in order to fix it,
|
||||
// some hacks are required, which isn't worth it considering that test contains invalid code (reassign of val property).
|
||||
// IGNORE_BACKEND: NATIVE
|
||||
// DISABLE_NATIVE
|
||||
// IGNORE_BACKEND_K2: ANY
|
||||
// FIR_STATUS: KT-35565
|
||||
// java.lang.AssertionError
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
// TARGET_BACKEND: NATIVE
|
||||
// test is disabled now because of https://youtrack.jetbrains.com/issue/KT-55426
|
||||
// IGNORE_BACKEND: NATIVE
|
||||
// IGNORE_NATIVE: cacheMode=STATIC_EVERYWHERE
|
||||
// IGNORE_NATIVE: cacheMode=STATIC_PER_FILE_EVERYWHERE
|
||||
|
||||
// MODULE: lib
|
||||
// FILE: lib.kt
|
||||
@@ -14,7 +15,7 @@ class Box(@Volatile var value: String)
|
||||
// MODULE: main(lib)
|
||||
// FILE: main.kt
|
||||
|
||||
@file:Suppress("INVISIBLE_MEMBER")
|
||||
@file:Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE")
|
||||
|
||||
import kotlin.native.concurrent.*
|
||||
import kotlin.concurrent.*
|
||||
|
||||
+2
-1
@@ -1,6 +1,7 @@
|
||||
// IGNORE_BACKEND: WASM
|
||||
// https://youtrack.jetbrains.com/issue/KT-44571/Segfault-on-unnecessary-int-unboxing
|
||||
// IGNORE_BACKEND: NATIVE
|
||||
// IGNORE_NATIVE: optimizationMode=DEBUG
|
||||
// IGNORE_NATIVE: optimizationMode=NO
|
||||
// NO_CHECK_LAMBDA_INLINING
|
||||
// FILE: 1.kt
|
||||
package test
|
||||
|
||||
@@ -81,7 +81,7 @@ public class KotlinTestUtils {
|
||||
private static final boolean AUTOMATICALLY_UNMUTE_PASSED_TESTS = false;
|
||||
private static final boolean AUTOMATICALLY_MUTE_FAILED_TESTS = false;
|
||||
|
||||
private static final Pattern DIRECTIVE_PATTERN = Pattern.compile("^//\\s*[!]?([A-Z_]+)(:[ \\t]*(.*))?$", Pattern.MULTILINE);
|
||||
private static final Pattern DIRECTIVE_PATTERN = Pattern.compile("^//\\s*[!]?([A-Z_0-9]+)(:[ \\t]*(.*))?$", Pattern.MULTILINE);
|
||||
|
||||
private KotlinTestUtils() {
|
||||
}
|
||||
|
||||
+85
-85
@@ -28886,6 +28886,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/multiplatform/callToJavaSuper.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt59613.kt")
|
||||
public void ignoreKt59613() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/kt59613.kt");
|
||||
}
|
||||
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM_IR, testDataFilePath);
|
||||
}
|
||||
@@ -28919,11 +28924,6 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/multiplatform/expectProperty.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt59613.kt")
|
||||
public void testKt59613() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/kt59613.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt60854.kt")
|
||||
public void testKt60854() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/kt60854.kt");
|
||||
@@ -28986,6 +28986,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/multiplatform/defaultArguments/superCall.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("typeAlias2.kt")
|
||||
public void ignoreTypeAlias2() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/defaultArguments/typeAlias2.kt");
|
||||
}
|
||||
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM_IR, testDataFilePath);
|
||||
}
|
||||
@@ -29109,11 +29114,6 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/multiplatform/defaultArguments/typeAlias.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("typeAlias2.kt")
|
||||
public void testTypeAlias2() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/defaultArguments/typeAlias2.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("withTypeParameter.kt")
|
||||
public void testWithTypeParameter() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/defaultArguments/withTypeParameter.kt");
|
||||
@@ -29170,13 +29170,13 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class K2 extends AbstractLightAnalysisModeTest {
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM_IR, testDataFilePath);
|
||||
@TestMetadata("actualInnerClassesFirMemberMapping.kt")
|
||||
public void ignoreActualInnerClassesFirMemberMapping() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/actualInnerClassesFirMemberMapping.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("actualInnerClassesFirMemberMapping.kt")
|
||||
public void testActualInnerClassesFirMemberMapping() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/actualInnerClassesFirMemberMapping.kt");
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM_IR, testDataFilePath);
|
||||
}
|
||||
|
||||
public void testAllFilesPresentInK2() throws Exception {
|
||||
@@ -29260,6 +29260,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class Basic extends AbstractLightAnalysisModeTest {
|
||||
@TestMetadata("anyMethodInExpect.kt")
|
||||
public void ignoreAnyMethodInExpect() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/anyMethodInExpect.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("expectActualFakeOverrides2.kt")
|
||||
public void ignoreExpectActualFakeOverrides2() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/expectActualFakeOverrides2.kt");
|
||||
@@ -29300,11 +29305,41 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/expectProperty.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("intersectionOverrideInCommonModule.kt")
|
||||
public void ignoreIntersectionOverrideInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/intersectionOverrideInCommonModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("intersectionOverrideWithDefaultParameterInCommonModule.kt")
|
||||
public void ignoreIntersectionOverrideWithDefaultParameterInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/intersectionOverrideWithDefaultParameterInCommonModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("localIntersectionOverrideInCommonModule.kt")
|
||||
public void ignoreLocalIntersectionOverrideInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/localIntersectionOverrideInCommonModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("localIntersectionOverrideWithDefaultParameterInCommonModule.kt")
|
||||
public void ignoreLocalIntersectionOverrideWithDefaultParameterInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/localIntersectionOverrideWithDefaultParameterInCommonModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("localSubstitutionOverrideInCommonModule.kt")
|
||||
public void ignoreLocalSubstitutionOverrideInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/localSubstitutionOverrideInCommonModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("noArgActualConstructor.kt")
|
||||
public void ignoreNoArgActualConstructor() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/noArgActualConstructor.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("nonExternalEquals.kt")
|
||||
public void ignoreNonExternalEquals() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/nonExternalEquals.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("overridesOfExpectMembers.kt")
|
||||
public void ignoreOverridesOfExpectMembers() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/overridesOfExpectMembers.kt");
|
||||
@@ -29315,6 +29350,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/removeExpectDeclarationsFromMetadata.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("substitutionOverrideInCommonModule.kt")
|
||||
public void ignoreSubstitutionOverrideInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/substitutionOverrideInCommonModule.kt");
|
||||
}
|
||||
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM_IR, testDataFilePath);
|
||||
}
|
||||
@@ -29333,11 +29373,6 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/multiplatform/k2/basic"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
|
||||
}
|
||||
|
||||
@TestMetadata("anyMethodInExpect.kt")
|
||||
public void testAnyMethodInExpect() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/anyMethodInExpect.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("correctParentForTypeParameter.kt")
|
||||
public void testCorrectParentForTypeParameter() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/correctParentForTypeParameter.kt");
|
||||
@@ -29433,16 +29468,6 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/interfaceMethodFromSuperTypeIsImplementedInOtherExpectSuperClass.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("intersectionOverrideInCommonModule.kt")
|
||||
public void testIntersectionOverrideInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/intersectionOverrideInCommonModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("intersectionOverrideWithDefaultParameterInCommonModule.kt")
|
||||
public void testIntersectionOverrideWithDefaultParameterInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/intersectionOverrideWithDefaultParameterInCommonModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt-51753-1.kt")
|
||||
public void testKt_51753_1() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/kt-51753-1.kt");
|
||||
@@ -29458,31 +29483,6 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/kt-56329.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("localIntersectionOverrideInCommonModule.kt")
|
||||
public void testLocalIntersectionOverrideInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/localIntersectionOverrideInCommonModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("localIntersectionOverrideWithDefaultParameterInCommonModule.kt")
|
||||
public void testLocalIntersectionOverrideWithDefaultParameterInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/localIntersectionOverrideWithDefaultParameterInCommonModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("localSubstitutionOverrideInCommonModule.kt")
|
||||
public void testLocalSubstitutionOverrideInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/localSubstitutionOverrideInCommonModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("nonExternalEquals.kt")
|
||||
public void testNonExternalEquals() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/nonExternalEquals.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("substitutionOverrideInCommonModule.kt")
|
||||
public void testSubstitutionOverrideInCommonModule() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/substitutionOverrideInCommonModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("transitiveSuperclassActualization.kt")
|
||||
public void testTransitiveSuperclassActualization() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/basic/transitiveSuperclassActualization.kt");
|
||||
@@ -29508,6 +29508,16 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class ComplexMatchings extends AbstractLightAnalysisModeTest {
|
||||
@TestMetadata("expectCtorlessFinalToActualObject.kt")
|
||||
public void ignoreExpectCtorlessFinalToActualObject() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/complexMatchings/expectCtorlessFinalToActualObject.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("expectCtorlessFinalToActualUnit.kt")
|
||||
public void ignoreExpectCtorlessFinalToActualUnit() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/complexMatchings/expectCtorlessFinalToActualUnit.kt");
|
||||
}
|
||||
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM_IR, testDataFilePath);
|
||||
}
|
||||
@@ -29515,16 +29525,6 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
public void testAllFilesPresentInComplexMatchings() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/multiplatform/k2/complexMatchings"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
|
||||
}
|
||||
|
||||
@TestMetadata("expectCtorlessFinalToActualObject.kt")
|
||||
public void testExpectCtorlessFinalToActualObject() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/complexMatchings/expectCtorlessFinalToActualObject.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("expectCtorlessFinalToActualUnit.kt")
|
||||
public void testExpectCtorlessFinalToActualUnit() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/complexMatchings/expectCtorlessFinalToActualUnit.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/codegen/box/multiplatform/k2/defaultArguments")
|
||||
@@ -29679,6 +29679,26 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class MigratedOldTests extends AbstractLightAnalysisModeTest {
|
||||
@TestMetadata("mpp1.kt")
|
||||
public void ignoreMpp1() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/migratedOldTests/mpp1.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("mpp2.kt")
|
||||
public void ignoreMpp2() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/migratedOldTests/mpp2.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("mpp_default_args.kt")
|
||||
public void ignoreMpp_default_args() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/migratedOldTests/mpp_default_args.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("remap_expect_property_ref.kt")
|
||||
public void ignoreRemap_expect_property_ref() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/migratedOldTests/remap_expect_property_ref.kt");
|
||||
}
|
||||
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM_IR, testDataFilePath);
|
||||
}
|
||||
@@ -29687,30 +29707,10 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/multiplatform/k2/migratedOldTests"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
|
||||
}
|
||||
|
||||
@TestMetadata("mpp1.kt")
|
||||
public void testMpp1() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/migratedOldTests/mpp1.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("mpp2.kt")
|
||||
public void testMpp2() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/migratedOldTests/mpp2.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("mpp_default_args.kt")
|
||||
public void testMpp_default_args() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/migratedOldTests/mpp_default_args.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("mpp_optional_expectation.kt")
|
||||
public void testMpp_optional_expectation() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/migratedOldTests/mpp_optional_expectation.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("remap_expect_property_ref.kt")
|
||||
public void testRemap_expect_property_ref() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/multiplatform/k2/migratedOldTests/remap_expect_property_ref.kt");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -98,6 +98,19 @@ To run blackbox compiler tests use:
|
||||
| `executionTimeout` | Max permitted duration of each individual test execution in milliseconds |
|
||||
| `sanitizer` | Run tests with sanitizer: `NONE` (default), `THREAD`. |
|
||||
|
||||
A test can be ignored for certain property values with the help of test directives within test source files:
|
||||
- `// IGNORE_NATIVE: <name>=<value>` to ignore test for both K1 and K2 frontends
|
||||
- `// IGNORE_NATIVE_K1: <name>=<value>` to ignore test for K1 frontend only
|
||||
- `// IGNORE_NATIVE_K2: <name>=<value>` to ignore test for K2 frontend only
|
||||
|
||||
Good examples are:
|
||||
- `// IGNORE_NATIVE: cacheMode=STATIC_EVERYWHERE`
|
||||
- `// IGNORE_NATIVE_K1: mode=ONE_STAGE_MULTI_MODULE`
|
||||
- `// IGNORE_NATIVE_K2: optimizationMode=OPT`
|
||||
- `// IGNORE_NATIVE: cacheMode=STATIC_EVERYWHERE && target=linux_x64`
|
||||
|
||||
Test will be ignored in case value of any `// IGNORE_NATIVE*` directive would match to an actual test run setting.
|
||||
|
||||
### Target-specific tests
|
||||
|
||||
There are also tests that are very Native-backend specific: tests for Kotlin/Native-specific function, C-interop tests, linkage tests, etc.
|
||||
|
||||
-623
File diff suppressed because it is too large
Load Diff
@@ -34,12 +34,6 @@ fun main() {
|
||||
suiteTestClassName = "NativeCodegenBoxTestGenerated",
|
||||
annotations = listOf(
|
||||
provider<UseExtTestCaseGroupProvider>(),
|
||||
disabledInOneStageMode(
|
||||
"codegen/box/coroutines/featureIntersection/defaultExpect.kt",
|
||||
"codegen/box/multiplatform/defaultArguments/*.kt",
|
||||
"codegen/box/multiplatform/migratedOldTests/*.kt",
|
||||
"codegen/boxInline/multiplatform/defaultArguments/receiversAndParametersInLambda.kt"
|
||||
)
|
||||
)
|
||||
) {
|
||||
model("codegen/box", targetBackend = TargetBackend.NATIVE)
|
||||
|
||||
+13
-1
@@ -9,6 +9,8 @@ import com.intellij.testFramework.TestDataFile
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.NativeBlackBoxTestSupport
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.PackageName
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.TestCaseId
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.compilation.CompilationToolException
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.group.isIgnoredTarget
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.runner.TestRun
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.runner.TestRunProvider
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.runner.TestRunners.createProperTestRunner
|
||||
@@ -17,6 +19,7 @@ import org.jetbrains.kotlin.konan.test.blackbox.support.util.TreeNode
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.util.getAbsoluteFile
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.util.joinPackageNames
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.util.prependPackageName
|
||||
import org.jetbrains.kotlin.test.services.JUnit5Assertions.fail
|
||||
import org.junit.jupiter.api.DynamicNode
|
||||
import org.junit.jupiter.api.DynamicTest.dynamicTest
|
||||
import org.junit.jupiter.api.extension.ExtendWith
|
||||
@@ -32,8 +35,17 @@ abstract class AbstractNativeBlackBoxTest {
|
||||
* This function should be called from a method annotated with [org.junit.jupiter.api.Test].
|
||||
*/
|
||||
fun runTest(@TestDataFile testDataFilePath: String) {
|
||||
val testCaseId = TestCaseId.TestDataFile(getAbsoluteFile(testDataFilePath))
|
||||
val absoluteTestFile = getAbsoluteFile(testDataFilePath)
|
||||
val testCaseId = TestCaseId.TestDataFile(absoluteTestFile)
|
||||
try {
|
||||
runTestCase(testCaseId)
|
||||
} catch (e: CompilationToolException) {
|
||||
// TODO find out the way not to re-read test source file, but to re-use already extracted test directives.
|
||||
if (testRunSettings.isIgnoredTarget(absoluteTestFile))
|
||||
println("There was an expected failure: CompilationToolException: ${e.reason}")
|
||||
else
|
||||
fail { e.reason }
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
-9
@@ -6,8 +6,6 @@
|
||||
package org.jetbrains.kotlin.konan.test.blackbox
|
||||
|
||||
import com.intellij.testFramework.TestDataFile
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.ClassLevelProperty
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.group.DisabledTestsIfProperty
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.settings.ExternalSourceTransformersProvider
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.util.ExternalSourceTransformer
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.util.ExternalSourceTransformers
|
||||
@@ -16,13 +14,6 @@ import org.jetbrains.kotlin.konan.test.blackbox.support.util.getAbsoluteFile
|
||||
import org.junit.jupiter.api.Tag
|
||||
import java.io.File
|
||||
|
||||
// Disable codegen/box/properties/lateinit/isInitializedAndDeinitialize tests with ONE_STAGE_MULTI_MODULE
|
||||
// They should be disabled only for K2 but this is not possible right now.
|
||||
@DisabledTestsIfProperty(
|
||||
sourceLocations = ["compiler/testData/codegen/box/properties/lateinit/isInitializedAndDeinitialize/*.kt"],
|
||||
property = ClassLevelProperty.TEST_MODE,
|
||||
propertyValue = "ONE_STAGE_MULTI_MODULE"
|
||||
)
|
||||
@Tag("codegen")
|
||||
abstract class AbstractNativeCodegenBoxTest : ExternalSourceTransformersProvider, AbstractNativeBlackBoxTest() {
|
||||
private val registeredSourceTransformers: ThreadSafeCache<File, MutableList<ExternalSourceTransformer>> = ThreadSafeCache()
|
||||
|
||||
+1
-1
@@ -54,7 +54,7 @@ internal class EnforcedProperties(testClass: Class<*>) {
|
||||
acceptableAnnotations[propertyType]?.contains(value) ?: true
|
||||
}
|
||||
|
||||
internal enum class ClassLevelProperty(shortName: String) {
|
||||
internal enum class ClassLevelProperty(val shortName: String) {
|
||||
TEST_TARGET("target"),
|
||||
TEST_MODE("mode"),
|
||||
COMPILER_PLUGINS("compilerPlugins"),
|
||||
|
||||
+2
-1
@@ -283,7 +283,8 @@ private object NativeTestSupport {
|
||||
kotlinNativeTargets,
|
||||
optimizationMode,
|
||||
useStaticCacheForUserLibraries,
|
||||
makePerFileCaches
|
||||
makePerFileCaches,
|
||||
cacheMode
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
+33
@@ -148,6 +148,39 @@ internal object TestDirectives : SimpleDirectivesContainer() {
|
||||
val FILECHECK_STAGE by stringDirective(
|
||||
description = "Specify a LLVM stage to dump LLVM IR after, and check it with LLVM FileCheck using its directives in test file"
|
||||
)
|
||||
|
||||
val DISABLE_NATIVE by stringDirective(
|
||||
description = "Test is not compiled/run with neither K1 nor K2 frontend and marked as disabled(GRAY)."
|
||||
)
|
||||
|
||||
val DISABLE_NATIVE_K1 by stringDirective(
|
||||
description = "Test is not compiled/run with K1 frontend and marked as disabled(GRAY)."
|
||||
)
|
||||
|
||||
val DISABLE_NATIVE_K2 by stringDirective(
|
||||
description = "Test is not compiled/run with K2 frontend and marked as disabled(GRAY)."
|
||||
)
|
||||
|
||||
val IGNORE_NATIVE by stringDirective(
|
||||
"""
|
||||
Usage: // IGNORE_NATIVE: property1=value1[ && property2=value2][ && property3=value3]
|
||||
Declares this test is expected to fail in described run configuration on both K1 and K2 frontends.
|
||||
""".trimIndent()
|
||||
)
|
||||
|
||||
val IGNORE_NATIVE_K1 by stringDirective(
|
||||
"""
|
||||
Usage: // IGNORE_NATIVE_K1: property1=value1[ && property2=value2][ && property3=value3]
|
||||
Declares this test is expected to fail in described run configuration on K1 frontend.
|
||||
""".trimIndent()
|
||||
)
|
||||
|
||||
val IGNORE_NATIVE_K2 by stringDirective(
|
||||
"""
|
||||
Usage: // IGNORE_NATIVE_K2: property1=value1[ && property2=value2][ && property3=value3]
|
||||
Declares this test is expected to fail in described run configuration on K2 frontend.
|
||||
""".trimIndent()
|
||||
)
|
||||
}
|
||||
|
||||
internal enum class TestKind {
|
||||
|
||||
+4
-1
@@ -8,6 +8,8 @@ package org.jetbrains.kotlin.konan.test.blackbox.support.compilation
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.LoggedData
|
||||
import org.jetbrains.kotlin.test.services.JUnit5Assertions.fail
|
||||
|
||||
class CompilationToolException(val reason: String) : Exception()
|
||||
|
||||
internal sealed interface TestCompilationResult<A : TestCompilationArtifact> {
|
||||
sealed interface ImmediateResult<A : TestCompilationArtifact> : TestCompilationResult<A> {
|
||||
val loggedData: LoggedData
|
||||
@@ -25,7 +27,8 @@ internal sealed interface TestCompilationResult<A : TestCompilationArtifact> {
|
||||
companion object {
|
||||
fun <A : TestCompilationArtifact> TestCompilationResult<A>.assertSuccess(): Success<A> = when (this) {
|
||||
is Success -> this
|
||||
is Failure -> fail { describeFailure() }
|
||||
is UnexpectedFailure -> fail { describeFailure() }
|
||||
is CompilationToolFailure -> throw CompilationToolException(describeFailure())
|
||||
is DependencyFailures -> fail { describeDependencyFailures() }
|
||||
}
|
||||
|
||||
|
||||
+8
@@ -6,11 +6,19 @@ package org.jetbrains.kotlin.konan.test.blackbox.support.group
|
||||
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.ClassLevelProperty
|
||||
|
||||
// Deprecated: Use test directives instead:
|
||||
// `IGNORE_BACKEND: NATIVE`, `IGNORE_BACKEND_K1: NATIVE`, `IGNORE_BACKEND_K2: NATIVE` if test fails in any tets config
|
||||
// `IGNORE_NATIVE`, `IGNORE_NATIVE_K1`, `IGNORE_NATIVE_K2` with a property matcher, for usual easy fails
|
||||
// `DISABLE_NATIVE`, `DISABLE_NATIVE_K1`, `DISABLE_NATIVE_K2` in case compiler crashes within JVM
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
internal annotation class DisabledTests(
|
||||
val sourceLocations: Array<String>
|
||||
)
|
||||
|
||||
// @DisabledTestsIfProperty(...) is intended primarily to turn off tests in bulk to reduce pressure on CI infrastructure for certain targets
|
||||
// To mark failed tests, please use the following test directives instead:
|
||||
// `IGNORE_NATIVE`, `IGNORE_NATIVE_K1`, `IGNORE_NATIVE_K2` with a property matcher, for usual easy fails
|
||||
// `DISABLE_NATIVE`, `DISABLE_NATIVE_K1`, `DISABLE_NATIVE_K2` for overcomplicated property combinations, or in case compiler crashes within JVM
|
||||
@Target(AnnotationTarget.CLASS)
|
||||
internal annotation class DisabledTestsIfProperty(
|
||||
val sourceLocations: Array<String>,
|
||||
|
||||
+117
-48
@@ -21,7 +21,13 @@ import org.jetbrains.kotlin.config.CompilerConfiguration
|
||||
import org.jetbrains.kotlin.config.LanguageFeature
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.*
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.TestCase.WithTestRunnerExtras
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.TestDirectives.DISABLE_NATIVE
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.TestDirectives.DISABLE_NATIVE_K1
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.TestDirectives.DISABLE_NATIVE_K2
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.TestDirectives.FILECHECK_STAGE
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.TestDirectives.IGNORE_NATIVE
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.TestDirectives.IGNORE_NATIVE_K1
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.TestDirectives.IGNORE_NATIVE_K2
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.runner.TestRunCheck
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.runner.TestRunChecks
|
||||
import org.jetbrains.kotlin.konan.test.blackbox.support.settings.*
|
||||
@@ -35,6 +41,9 @@ import org.jetbrains.kotlin.resolve.ImportPath
|
||||
import org.jetbrains.kotlin.resolve.checkers.OptInNames
|
||||
import org.jetbrains.kotlin.test.*
|
||||
import org.jetbrains.kotlin.test.InTextDirectivesUtils.*
|
||||
import org.jetbrains.kotlin.test.directives.CodegenTestDirectives.IGNORE_BACKEND
|
||||
import org.jetbrains.kotlin.test.directives.CodegenTestDirectives.IGNORE_BACKEND_K1
|
||||
import org.jetbrains.kotlin.test.directives.CodegenTestDirectives.IGNORE_BACKEND_K2
|
||||
import org.jetbrains.kotlin.test.services.JUnit5Assertions.assertTrue
|
||||
import org.jetbrains.kotlin.test.services.JUnit5Assertions.fail
|
||||
import org.jetbrains.kotlin.utils.addIfNotNull
|
||||
@@ -72,14 +81,7 @@ internal class ExtTestCaseGroupProvider : TestCaseGroupProvider, TestDisposable(
|
||||
testDataFile = testDataFile,
|
||||
structureFactory = structureFactory,
|
||||
customSourceTransformers = settings.get<ExternalSourceTransformersProvider>().getSourceTransformers(testDataFile),
|
||||
testRoots = settings.get(),
|
||||
generatedSources = settings.get(),
|
||||
customKlibs = settings.get(),
|
||||
pipelineType = settings.get(),
|
||||
testMode = settings.get(),
|
||||
cacheMode = settings.get(),
|
||||
optimizationMode = settings.get(),
|
||||
timeouts = settings.get(),
|
||||
settings = settings,
|
||||
)
|
||||
|
||||
if (extTestDataFile.isRelevant)
|
||||
@@ -100,15 +102,17 @@ private class ExtTestDataFile(
|
||||
private val testDataFile: File,
|
||||
structureFactory: ExtTestDataFileStructureFactory,
|
||||
customSourceTransformers: ExternalSourceTransformers?,
|
||||
testRoots: TestRoots,
|
||||
private val generatedSources: GeneratedSources,
|
||||
private val customKlibs: CustomKlibs,
|
||||
pipelineType: PipelineType,
|
||||
testMode: TestMode,
|
||||
cacheMode: CacheMode,
|
||||
optimizationMode: OptimizationMode,
|
||||
private val timeouts: Timeouts,
|
||||
settings: Settings,
|
||||
) {
|
||||
private val testRoots = settings.get<TestRoots>()
|
||||
private val generatedSources = settings.get<GeneratedSources>()
|
||||
private val customKlibs = settings.get<CustomKlibs>()
|
||||
private val timeouts = settings.get<Timeouts>()
|
||||
private val pipelineType = settings.get<PipelineType>()
|
||||
private val testMode = settings.get<TestMode>()
|
||||
private val cacheMode = settings.get<CacheMode>()
|
||||
private val optimizationMode = settings.get<OptimizationMode>()
|
||||
|
||||
private val structure by lazy {
|
||||
val allSourceTransformers: ExternalSourceTransformers = if (customSourceTransformers.isNullOrEmpty())
|
||||
MANDATORY_SOURCE_TRANSFORMERS
|
||||
@@ -118,6 +122,8 @@ private class ExtTestDataFile(
|
||||
structureFactory.ExtTestDataFileStructure(testDataFile, allSourceTransformers)
|
||||
}
|
||||
|
||||
private val isIgnoredTarget: Boolean = settings.isIgnoredTarget(structure.directives)
|
||||
|
||||
private val testDataFileSettings by lazy {
|
||||
val optIns = structure.directives.multiValues(OPT_IN_DIRECTIVE)
|
||||
val optInsForSourceCode = optIns subtract OPT_INS_PURELY_FOR_COMPILER
|
||||
@@ -145,7 +151,7 @@ private class ExtTestDataFile(
|
||||
|
||||
val isRelevant: Boolean =
|
||||
isCompatibleTarget(TargetBackend.NATIVE, testDataFile) // Checks TARGET_BACKEND/DONT_TARGET_EXACT_BACKEND directives.
|
||||
&& !isIgnoredTarget(pipelineType, testDataFile, TargetBackend.NATIVE) // Checks IGNORE_BACKEND directives.
|
||||
&& !isDisabledNative(pipelineType, structure.directives)
|
||||
&& testDataFileSettings.languageSettings.none { it in INCOMPATIBLE_LANGUAGE_SETTINGS }
|
||||
&& INCOMPATIBLE_DIRECTIVES.none { it in structure.directives }
|
||||
&& structure.directives[API_VERSION_DIRECTIVE] !in INCOMPATIBLE_API_VERSIONS
|
||||
@@ -157,34 +163,6 @@ private class ExtTestDataFile(
|
||||
&& pipelineType == PipelineType.K2
|
||||
&& testMode == TestMode.ONE_STAGE_MULTI_MODULE)
|
||||
|
||||
private fun isIgnoredTarget(pipelineType: PipelineType, testDataFile: File, backend: TargetBackend): Boolean {
|
||||
return when (pipelineType) {
|
||||
PipelineType.K1 ->
|
||||
isIgnoredTarget(
|
||||
backend,
|
||||
testDataFile,
|
||||
/*includeAny = */true,
|
||||
IGNORE_BACKEND_DIRECTIVE_PREFIX,
|
||||
IGNORE_BACKEND_K1_DIRECTIVE_PREFIX
|
||||
)
|
||||
PipelineType.K2 ->
|
||||
isIgnoredTarget(
|
||||
backend,
|
||||
testDataFile,
|
||||
/*includeAny = */true,
|
||||
IGNORE_BACKEND_DIRECTIVE_PREFIX,
|
||||
IGNORE_BACKEND_K2_DIRECTIVE_PREFIX
|
||||
)
|
||||
PipelineType.DEFAULT ->
|
||||
isIgnoredTarget(
|
||||
backend,
|
||||
testDataFile,
|
||||
/*includeAny = */true,
|
||||
IGNORE_BACKEND_DIRECTIVE_PREFIX,
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
private fun assembleFreeCompilerArgs(): TestCompilerArgs {
|
||||
val args = mutableListOf<String>()
|
||||
testDataFileSettings.languageSettings.sorted().mapTo(args) { "-XXLanguage:$it" }
|
||||
@@ -214,6 +192,12 @@ private class ExtTestDataFile(
|
||||
private fun determineIfStandaloneTest(): Boolean = with(structure) {
|
||||
if (directives.contains(NATIVE_STANDALONE_DIRECTIVE)) return true
|
||||
if (directives.contains(FILECHECK_STAGE.name)) return true
|
||||
if (isIgnoredTarget) return true
|
||||
// To make the debug of possible failed testruns easier, it makes sense to run dodgy tests alone
|
||||
if (directives.contains(IGNORE_NATIVE.name) ||
|
||||
directives.contains(IGNORE_NATIVE_K1.name) ||
|
||||
directives.contains(IGNORE_NATIVE_K2.name)
|
||||
) return true
|
||||
|
||||
var isStandaloneTest = false
|
||||
|
||||
@@ -531,8 +515,11 @@ private class ExtTestDataFile(
|
||||
modules = modules,
|
||||
freeCompilerArgs = assembleFreeCompilerArgs(),
|
||||
nominalPackageName = testDataFileSettings.nominalPackageName,
|
||||
checks = TestRunChecks.Default(timeouts.executionTimeout)
|
||||
.copy(fileCheckMatcher = fileCheckStage?.let { TestRunCheck.FileCheckMatcher(settings, testDataFile) }),
|
||||
checks = TestRunChecks.Default(timeouts.executionTimeout).copy(
|
||||
fileCheckMatcher = fileCheckStage?.let { TestRunCheck.FileCheckMatcher(settings, testDataFile) },
|
||||
exitCodeCheck = TestRunCheck.ExitCode.Expected(0).takeUnless { isIgnoredTarget },
|
||||
expectedFailureCheck = TestRunCheck.ExpectedFailure.takeIf { isIgnoredTarget },
|
||||
),
|
||||
fileCheckStage = fileCheckStage,
|
||||
extras = WithTestRunnerExtras(runnerType = TestRunnerType.DEFAULT)
|
||||
)
|
||||
@@ -612,7 +599,7 @@ private class ExtTestDataFileSettings(
|
||||
private typealias SharedModuleGenerator = (sharedModulesDir: File) -> TestModule.Shared?
|
||||
private typealias SharedModuleCache = (moduleName: String, generator: SharedModuleGenerator) -> TestModule.Shared?
|
||||
|
||||
private class ExtTestDataFileStructureFactory(parentDisposable: Disposable) : TestDisposable(parentDisposable) {
|
||||
private class ExtTestDataFileStructureFactory(parentDisposable: Disposable?) : TestDisposable(parentDisposable) {
|
||||
private val psiFactory = createPsiFactory(parentDisposable = this)
|
||||
|
||||
inner class ExtTestDataFileStructure(originalTestDataFile: File, sourceTransformers: ExternalSourceTransformers) {
|
||||
@@ -882,3 +869,85 @@ private class ExtTestDataFileStructureFactory(parentDisposable: Disposable) : Te
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
internal fun isDisabledNative(pipelineType: PipelineType, directives: Directives): Boolean {
|
||||
return when (pipelineType) {
|
||||
PipelineType.K1 -> directives.contains(DISABLE_NATIVE.name) || directives.contains(DISABLE_NATIVE_K1.name)
|
||||
PipelineType.K2 -> directives.contains(DISABLE_NATIVE.name) || directives.contains(DISABLE_NATIVE_K2.name)
|
||||
PipelineType.DEFAULT -> directives.contains(DISABLE_NATIVE.name)
|
||||
}
|
||||
}
|
||||
|
||||
internal fun Settings.isIgnoredTarget(testDataFile: File): Boolean {
|
||||
val extTestDataFileStructure =
|
||||
ExtTestDataFileStructureFactory(parentDisposable = null).ExtTestDataFileStructure(testDataFile, emptyList())
|
||||
return isIgnoredTarget(extTestDataFileStructure.directives)
|
||||
}
|
||||
|
||||
internal fun Settings.isIgnoredTarget(directives: Directives): Boolean {
|
||||
return isIgnoredWithIGNORE_BACKEND(directives) ||
|
||||
isIgnoredWithIGNORE_NATIVE(directives)
|
||||
}
|
||||
|
||||
// Mimics `InTextDirectivesUtils.isIgnoredTarget(NATIVE, file)` but does not require file contents, but only already parsed directives.
|
||||
private fun Settings.isIgnoredWithIGNORE_BACKEND(directives: Directives): Boolean {
|
||||
val containsNativeOrAny: (List<String>) -> Boolean = { TargetBackend.NATIVE.name in it || TargetBackend.ANY.name in it }
|
||||
|
||||
if (directives.listValues(IGNORE_BACKEND.name)?.let(containsNativeOrAny) == true)
|
||||
return true
|
||||
when (get<PipelineType>()) {
|
||||
PipelineType.K1 ->
|
||||
if (directives.listValues(IGNORE_BACKEND_K1.name)?.let(containsNativeOrAny) == true)
|
||||
return true
|
||||
PipelineType.K2 ->
|
||||
if (directives.listValues(IGNORE_BACKEND_K2.name)?.let(containsNativeOrAny) == true)
|
||||
return true
|
||||
else -> {}
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
private val CACHE_MODE_NAMES = CacheMode.Alias.entries.map { it.name }
|
||||
private val TEST_MODE_NAMES = TestMode.entries.map { it.name }
|
||||
private val OPTIMIZATION_MODE_NAMES = OptimizationMode.entries.map { it.name }
|
||||
|
||||
private fun Settings.isIgnoredWithIGNORE_NATIVE(
|
||||
directives: Directives,
|
||||
): Boolean {
|
||||
val directiveValues = buildList {
|
||||
directives.listValues(IGNORE_NATIVE.name)?.let { addAll(it) }
|
||||
when (get<PipelineType>()) {
|
||||
PipelineType.K1 -> directives.listValues(IGNORE_NATIVE_K1.name)?.let { addAll(it) }
|
||||
PipelineType.K2 -> directives.listValues(IGNORE_NATIVE_K2.name)?.let { addAll(it) }
|
||||
else -> {}
|
||||
}
|
||||
}
|
||||
// Boolean evaluation of expressions like `property1=value1 && property2=value2`
|
||||
directiveValues.forEach {
|
||||
val split = it.split("&&")
|
||||
val booleanList = split.map {
|
||||
val matchResult = "(.+)=(.+)".toRegex().find(it.trim())
|
||||
?: throw AssertionError("Invalid format for IGNORE_NATIVE* directive ($it). Must be <property>=<value>")
|
||||
val propName = matchResult.groups[1]?.value
|
||||
val (actualValue, supportedValues) = when (propName) {
|
||||
ClassLevelProperty.CACHE_MODE.shortName -> get<CacheMode>().alias.name to CACHE_MODE_NAMES
|
||||
ClassLevelProperty.TEST_MODE.shortName -> get<TestMode>().name to TEST_MODE_NAMES
|
||||
ClassLevelProperty.OPTIMIZATION_MODE.shortName -> get<OptimizationMode>().name to OPTIMIZATION_MODE_NAMES
|
||||
ClassLevelProperty.TEST_TARGET.shortName -> get<KotlinNativeTargets>().testTarget.name to null
|
||||
else -> throw AssertionError("ClassLevelProperty name: $propName is not yet supported in IGNORE_NATIVE* test directives.")
|
||||
}
|
||||
val valueFromTestDirective = matchResult.groups[2]?.value!!
|
||||
supportedValues?.let {
|
||||
if (actualValue !in it)
|
||||
throw AssertionError("Internal error: Test run value $propName=$actualValue is not in expected supported values: $it")
|
||||
if (valueFromTestDirective !in it)
|
||||
throw AssertionError("Test directive `IGNORE_NATIVE*: $propName=$valueFromTestDirective` has unsupported value. Supported are: $it")
|
||||
}
|
||||
actualValue == valueFromTestDirective
|
||||
}
|
||||
val matches = booleanList.reduce { a, b -> a && b }
|
||||
if (matches)
|
||||
return true
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
+1
@@ -226,6 +226,7 @@ internal class StandardTestCaseGroupProvider : TestCaseGroupProvider {
|
||||
checks = TestRunChecks(
|
||||
computeExecutionTimeoutCheck(settings, expectedTimeoutFailure),
|
||||
computeExitCodeCheck(testKind, registeredDirectives, location),
|
||||
expectedFailureCheck = null,
|
||||
computeOutputDataFileCheck(testDataFile, registeredDirectives, location),
|
||||
lldbSpec?.let { OutputMatcher { output -> lldbSpec.checkLLDBOutput(output, settings.get()) } },
|
||||
fileCheckMatcher = null,
|
||||
|
||||
+16
-1
@@ -96,7 +96,7 @@ internal abstract class AbstractLocalProcessRunner<R>(protected val checks: Test
|
||||
internal abstract class LocalResultHandler<R>(
|
||||
runResult: RunResult,
|
||||
private val visibleProcessName: String,
|
||||
private val checks: TestRunChecks
|
||||
protected val checks: TestRunChecks
|
||||
) : AbstractResultHandler<R>(runResult) {
|
||||
override fun handle(): R {
|
||||
checks.forEach { check ->
|
||||
@@ -107,6 +107,21 @@ internal abstract class LocalResultHandler<R>(
|
||||
is ExecutionTimeout.ShouldExceed -> verifyExpectation(!runResult.hasFinishedOnTime) {
|
||||
"Test is expected to fail with exceeded timeout, which hasn't happened."
|
||||
}
|
||||
is TestRunCheck.ExpectedFailure -> {
|
||||
val testReport = runResult.processOutput.stdOut.testReport
|
||||
verifyExpectation(testReport != null) {
|
||||
"testReport is expected to be non-null"
|
||||
}
|
||||
verifyExpectation(!testReport!!.isEmpty()) {
|
||||
"testReport is expected to be non-empty"
|
||||
}
|
||||
verifyExpectation(testReport.failedTests.isNotEmpty()) {
|
||||
"Test did not fail as expected"
|
||||
}
|
||||
verifyExpectation(testReport.passedTests.isEmpty()) {
|
||||
"Test unexpectedly passed"
|
||||
}
|
||||
}
|
||||
is ExitCode -> {
|
||||
// Don't check exit code if it is unknown.
|
||||
val knownExitCode: Int = runResult.exitCode ?: return@forEach
|
||||
|
||||
+10
-1
@@ -83,8 +83,17 @@ internal class ResultHandler(
|
||||
)
|
||||
}
|
||||
|
||||
if (checks.expectedFailureCheck !is TestRunCheck.ExpectedFailure)
|
||||
verifyNoSuchTests(testReport.failedTests, "There are failed tests")
|
||||
|
||||
else {
|
||||
runResult.processOutput.stdOut.filteredOutput.let {
|
||||
if (it.isNotEmpty())
|
||||
println("Failure is expected. Exit code=${runResult.exitCode}, filtered test output is below:\n$it")
|
||||
else
|
||||
println("Failure is expected. Exit code=${runResult.exitCode}, filtered test output is empty.")
|
||||
}
|
||||
verifyNoSuchTests(testReport.passedTests, "There are unexpectedly passed tests")
|
||||
}
|
||||
assumeFalse(testReport.ignoredTests.isNotEmpty() && testReport.passedTests.isEmpty(), "Test case is disabled")
|
||||
}
|
||||
|
||||
|
||||
+7
-2
@@ -22,6 +22,8 @@ internal sealed interface TestRunCheck {
|
||||
class Expected(val expectedExitCode: Int) : ExitCode()
|
||||
}
|
||||
|
||||
object ExpectedFailure : TestRunCheck
|
||||
|
||||
class OutputDataFile(val file: File) : TestRunCheck
|
||||
|
||||
class OutputMatcher(val match: (String) -> Boolean): TestRunCheck
|
||||
@@ -31,7 +33,8 @@ internal sealed interface TestRunCheck {
|
||||
|
||||
internal data class TestRunChecks(
|
||||
val executionTimeoutCheck: ExecutionTimeout,
|
||||
private val exitCodeCheck: ExitCode,
|
||||
private val exitCodeCheck: ExitCode?,
|
||||
val expectedFailureCheck: ExpectedFailure?,
|
||||
val outputDataFile: OutputDataFile?,
|
||||
val outputMatcher: OutputMatcher?,
|
||||
val fileCheckMatcher: FileCheckMatcher?,
|
||||
@@ -39,7 +42,8 @@ internal data class TestRunChecks(
|
||||
|
||||
override fun iterator() = iterator {
|
||||
yield(executionTimeoutCheck)
|
||||
yield(exitCodeCheck)
|
||||
yieldIfNotNull(exitCodeCheck)
|
||||
yieldIfNotNull(expectedFailureCheck)
|
||||
yieldIfNotNull(outputDataFile)
|
||||
yieldIfNotNull(outputMatcher)
|
||||
yieldIfNotNull(fileCheckMatcher)
|
||||
@@ -51,6 +55,7 @@ internal data class TestRunChecks(
|
||||
fun Default(timeout: Duration) = TestRunChecks(
|
||||
executionTimeoutCheck = ExecutionTimeout.ShouldNotExceed(timeout),
|
||||
exitCodeCheck = ExitCode.Expected(0),
|
||||
expectedFailureCheck = null,
|
||||
outputDataFile = null,
|
||||
outputMatcher = null,
|
||||
fileCheckMatcher = null,
|
||||
|
||||
+4
-1
@@ -210,6 +210,7 @@ internal sealed class CacheMode {
|
||||
abstract val staticCacheForDistributionLibrariesRootDir: File?
|
||||
abstract val useStaticCacheForUserLibraries: Boolean
|
||||
abstract val makePerFileCaches: Boolean
|
||||
abstract val alias: Alias
|
||||
|
||||
val useStaticCacheForDistributionLibraries: Boolean get() = staticCacheForDistributionLibrariesRootDir != null
|
||||
|
||||
@@ -217,6 +218,7 @@ internal sealed class CacheMode {
|
||||
override val staticCacheForDistributionLibrariesRootDir: File? get() = null
|
||||
override val useStaticCacheForUserLibraries: Boolean get() = false
|
||||
override val makePerFileCaches: Boolean = false
|
||||
override val alias = Alias.NO
|
||||
}
|
||||
|
||||
class WithStaticCache(
|
||||
@@ -224,7 +226,8 @@ internal sealed class CacheMode {
|
||||
kotlinNativeTargets: KotlinNativeTargets,
|
||||
optimizationMode: OptimizationMode,
|
||||
override val useStaticCacheForUserLibraries: Boolean,
|
||||
override val makePerFileCaches: Boolean
|
||||
override val makePerFileCaches: Boolean,
|
||||
override val alias: Alias,
|
||||
) : CacheMode() {
|
||||
override val staticCacheForDistributionLibrariesRootDir: File = File(distribution.klib)
|
||||
.resolve("cache")
|
||||
|
||||
Reference in New Issue
Block a user