Created module idea-test-framework and moved classes needed for idea tests there

Moved tests for completion and their test data into module idea-completion
This commit is contained in:
Valentin Kipyatkov
2015-04-13 18:11:53 +03:00
parent 63825c45dd
commit bb808b5620
1303 changed files with 1741 additions and 1733 deletions
@@ -0,0 +1,9 @@
fun foo(p: String) {
for (i in p.<caret>)
}
fun String.extFun(): Collection<Int>{}
// EXIST: toString
// EXIST: substring
// EXIST: extFun
@@ -0,0 +1,14 @@
trait X
trait Y
fun X.iterator(): Y
fun Y.next(): Int
fun Y.hasNext(): Boolean
fun foo(x: X, y: Y) {
for (i in <caret>)
}
// EXIST: x
// ABSENT: y
@@ -0,0 +1,9 @@
fun<T> xxx1(): T {}
fun<T : Collection<String>> xxx2(): T {}
fun foo() {
for (i in <caret>)
}
// ABSENT: xxx1
// EXIST: xxx2
@@ -0,0 +1,12 @@
fun foo(p: String?) {
for (i in <caret>)
}
fun f(): Collection<Int>? {}
// ABSENT: { lookupString:"p", itemText: "p" }
// EXIST: { lookupString:"p", itemText: "!! p", typeText:"String?" }
// EXIST: { lookupString:"p", itemText: "?: p", typeText:"String?" }
// ABSENT: { lookupString:"f", itemText: "f" }
// EXIST: { lookupString:"f", itemText: "!! f", typeText:"Collection<Int>?" }
// EXIST: { lookupString:"f", itemText: "?: f", typeText:"Collection<Int>?" }
@@ -0,0 +1,16 @@
fun foo(p1: String, p2: Int, p3: Collection<Int>) {
for (i in <caret>)
}
fun f1(): String{}
fun f2(): Int{}
fun f3(): Iterable<Char>{}
// EXIST: p1
// ABSENT: p2
// EXIST: p3
// EXIST: f1
// ABSENT: f2
// EXIST: f3
// EXIST: { lookupString:"listOf", itemText: "listOf", tailText: "(vararg values: T) (kotlin)", typeText:"List<T>" }
@@ -0,0 +1,8 @@
fun foo(p1: Any, p2: Any) {
if (p1 is String) {
for (i in <caret>)
}
}
// EXIST: p1
// ABSENT: p2
@@ -0,0 +1,13 @@
trait X
trait Y: X
trait Z
fun foo(p1: Collection<X>, p2: Collection<Y>, p3: Collection<Z>, p4: Collection<X?>) {
for (i: X in <caret>)
}
// EXIST: p1
// EXIST: p2
// ABSENT: p3
// ABSENT: p4
// EXIST: { lookupString:"listOf", itemText: "listOf", tailText: "(vararg values: T) (kotlin)", typeText:"List<T>" }