summaryrefslogtreecommitdiff
path: root/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/kotlin/idea/tests/testData/quickfix/createFromUsage')
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMember.after.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMember.before.Main.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInner.after.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInner.before.Main.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerPartialSubstitution.after.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerPartialSubstitution.before.Main.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerWithReceiverArg.after.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerWithReceiverArg.before.Main.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberPartialSubstitution.after.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberPartialSubstitution.before.Main.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMember.after.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMember.before.Main.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberPartialSubstitution.after.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberPartialSubstitution.before.Main.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberWithReceiverArg.after.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberWithReceiverArg.before.Main.kt1
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/invoke/lambdaArgument.kt7
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/invoke/lambdaArgument.kt.after13
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createTypeParameter/inContainingDeclaration/classWithExplicationAndRecursiveUpperBound.kt2
-rw-r--r--plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createTypeParameter/inContainingDeclaration/classWithExplicationAndRecursiveUpperBound.kt.after2
20 files changed, 24 insertions, 16 deletions
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMember.after.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMember.after.kt
index f62407f96f96..8a86545fd6b2 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMember.after.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMember.after.kt
@@ -1,5 +1,6 @@
// "Create class 'Foo'" "true"
// ERROR: Unresolved reference: Foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
internal fun test() = B.Foo<Int, String>(2, "2")
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMember.before.Main.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMember.before.Main.kt
index 194b187a194b..a14fd14a46c5 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMember.before.Main.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMember.before.Main.kt
@@ -1,5 +1,6 @@
// "Create class 'Foo'" "true"
// ERROR: Unresolved reference: Foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
internal fun test() = B.<caret>Foo<Int, String>(2, "2")
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInner.after.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInner.after.kt
index 6d9af98f681a..12cdffdb5a1a 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInner.after.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInner.after.kt
@@ -1,5 +1,6 @@
// "Create class 'Foo'" "true"
// ERROR: Unresolved reference: Foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
internal fun test() = b.Foo<Int, String>(2, "2")
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInner.before.Main.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInner.before.Main.kt
index ee27a78a071e..2d1d6fb8d5da 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInner.before.Main.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInner.before.Main.kt
@@ -1,5 +1,6 @@
// "Create class 'Foo'" "true"
// ERROR: Unresolved reference: Foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
internal fun test() = b.<caret>Foo<Int, String>(2, "2")
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerPartialSubstitution.after.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerPartialSubstitution.after.kt
index 2bb5082fb6b4..f91bf4cb0f53 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerPartialSubstitution.after.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerPartialSubstitution.after.kt
@@ -1,5 +1,6 @@
// "Create class 'Foo'" "true"
// ERROR: Unresolved reference: Foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
internal fun test() = b.Foo<String>(2, "2")
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerPartialSubstitution.before.Main.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerPartialSubstitution.before.Main.kt
index a372a98d192a..1586a39656bb 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerPartialSubstitution.before.Main.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerPartialSubstitution.before.Main.kt
@@ -1,5 +1,6 @@
// "Create class 'Foo'" "true"
// ERROR: Unresolved reference: Foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
internal fun test() = b.<caret>Foo<String>(2, "2")
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerWithReceiverArg.after.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerWithReceiverArg.after.kt
index 4e8ad4506682..aca27cf9a161 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerWithReceiverArg.after.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerWithReceiverArg.after.kt
@@ -1,5 +1,6 @@
// "Create class 'Foo'" "true"
// ERROR: Unresolved reference: Foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
internal fun test() = b.Foo<T, Int, String>(2, "2")
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerWithReceiverArg.before.Main.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerWithReceiverArg.before.Main.kt
index 759291470a79..4329e12ee95d 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerWithReceiverArg.before.Main.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberInnerWithReceiverArg.before.Main.kt
@@ -1,5 +1,6 @@
// "Create class 'Foo'" "true"
// ERROR: Unresolved reference: Foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
internal fun test() = b.<caret>Foo<T, Int, String>(2, "2")
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberPartialSubstitution.after.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberPartialSubstitution.after.kt
index 5aa81397ff8e..a3859606c32a 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberPartialSubstitution.after.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberPartialSubstitution.after.kt
@@ -1,5 +1,6 @@
// "Create class 'Foo'" "true"
// ERROR: Unresolved reference: Foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
internal fun test() = B.Foo<String>(2, "2")
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberPartialSubstitution.before.Main.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberPartialSubstitution.before.Main.kt
index b7f2e9895dfb..99c34c118ad6 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberPartialSubstitution.before.Main.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createClass/callExpression/typeArguments/javaClassMemberPartialSubstitution.before.Main.kt
@@ -1,5 +1,6 @@
// "Create class 'Foo'" "true"
// ERROR: Unresolved reference: Foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
internal fun test() = B.<caret>Foo<String>(2, "2")
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMember.after.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMember.after.kt
index ebc3a95cc97b..e143356fb0ab 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMember.after.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMember.after.kt
@@ -1,5 +1,6 @@
// "Create member function 'B.foo'" "true"
// ERROR: Unresolved reference: foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
fun test(): Int {
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMember.before.Main.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMember.before.Main.kt
index 0c990c906bac..2e4452583089 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMember.before.Main.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMember.before.Main.kt
@@ -1,5 +1,6 @@
// "Create member function 'B.foo'" "true"
// ERROR: Unresolved reference: foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
fun test(): Int {
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberPartialSubstitution.after.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberPartialSubstitution.after.kt
index 7a7b1758819e..c803a60b957f 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberPartialSubstitution.after.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberPartialSubstitution.after.kt
@@ -1,5 +1,6 @@
// "Create member function 'B.foo'" "true"
// ERROR: Unresolved reference: foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
fun test(): Int {
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberPartialSubstitution.before.Main.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberPartialSubstitution.before.Main.kt
index c1a57bfbb18f..f704fee53707 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberPartialSubstitution.before.Main.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberPartialSubstitution.before.Main.kt
@@ -1,5 +1,6 @@
// "Create member function 'B.foo'" "true"
// ERROR: Unresolved reference: foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
fun test(): Int {
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberWithReceiverArg.after.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberWithReceiverArg.after.kt
index ebc3a95cc97b..e143356fb0ab 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberWithReceiverArg.after.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberWithReceiverArg.after.kt
@@ -1,5 +1,6 @@
// "Create member function 'B.foo'" "true"
// ERROR: Unresolved reference: foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
fun test(): Int {
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberWithReceiverArg.before.Main.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberWithReceiverArg.before.Main.kt
index d8428c3b7d33..baaaab7473ac 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberWithReceiverArg.before.Main.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/call/typeArguments/javaClassMemberWithReceiverArg.before.Main.kt
@@ -1,5 +1,6 @@
// "Create member function 'B.foo'" "true"
// ERROR: Unresolved reference: foo
+// ERROR: 'public' property exposes its 'public/*package*/' type B
class A<T> internal constructor(val b: B<T>) {
fun test(): Int {
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/invoke/lambdaArgument.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/invoke/lambdaArgument.kt
index 9fbd6a0cd027..697f6b66a0c7 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/invoke/lambdaArgument.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/invoke/lambdaArgument.kt
@@ -1,4 +1,9 @@
-// "Create extension function 'Test.invoke'" "true"
+// "Create extension function 'Test.invoke'" "false"
+// ACTION: Add explicit type arguments
+// ACTION: Create function 't'
+// ERROR: Unresolved reference. None of the following candidates is applicable because of receiver type mismatch: <br>public operator fun <T, R> DeepRecursiveFunction<TypeVariable(T), TypeVariable(R)>.invoke(value: TypeVariable(T)): TypeVariable(R) defined in kotlin
+
+// KTIJ-1262 "Create extension function 'Test.invoke'" quickfix should suggest for variable with lambda argument
class Test
fun test() {
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/invoke/lambdaArgument.kt.after b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/invoke/lambdaArgument.kt.after
deleted file mode 100644
index 70f64b900eb0..000000000000
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createFunction/invoke/lambdaArgument.kt.after
+++ /dev/null
@@ -1,13 +0,0 @@
-// "Create extension function 'Test.invoke'" "true"
-class Test
-
-fun test() {
- var t = Test()
- t{
-
- }
-}
-
-private operator fun Test.invoke(function: () -> Unit) {
- TODO("Not yet implemented")
-}
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createTypeParameter/inContainingDeclaration/classWithExplicationAndRecursiveUpperBound.kt b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createTypeParameter/inContainingDeclaration/classWithExplicationAndRecursiveUpperBound.kt
index 670ec66e4fcf..3695e8cd2094 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createTypeParameter/inContainingDeclaration/classWithExplicationAndRecursiveUpperBound.kt
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createTypeParameter/inContainingDeclaration/classWithExplicationAndRecursiveUpperBound.kt
@@ -2,7 +2,7 @@
// ERROR: Unresolved reference: _
// ERROR: Unresolved reference: _
// ERROR: Unresolved reference: _
-// ERROR: Type mismatch: inferred type is A<I> but A<List<[ERROR : _]>> was expected
+// ERROR: Type mismatch: inferred type is A<I> but A<List<[Error type: Unresolved type for _]>> was expected
// COMPILER_ARGUMENTS: -XXLanguage:-NewInference
class A<T : List<T>>
diff --git a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createTypeParameter/inContainingDeclaration/classWithExplicationAndRecursiveUpperBound.kt.after b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createTypeParameter/inContainingDeclaration/classWithExplicationAndRecursiveUpperBound.kt.after
index f681c9ba0403..93b3367b5f22 100644
--- a/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createTypeParameter/inContainingDeclaration/classWithExplicationAndRecursiveUpperBound.kt.after
+++ b/plugins/kotlin/idea/tests/testData/quickfix/createFromUsage/createTypeParameter/inContainingDeclaration/classWithExplicationAndRecursiveUpperBound.kt.after
@@ -2,7 +2,7 @@
// ERROR: Unresolved reference: _
// ERROR: Unresolved reference: _
// ERROR: Unresolved reference: _
-// ERROR: Type mismatch: inferred type is A<I> but A<List<[ERROR : _]>> was expected
+// ERROR: Type mismatch: inferred type is A<I> but A<List<[Error type: Unresolved type for _]>> was expected
// COMPILER_ARGUMENTS: -XXLanguage:-NewInference
class A<T : List<T>>