From 57763e10e05456a96a1823afdb1a0c1f64e23352 Mon Sep 17 00:00:00 2001 From: Alexey Sedunov Date: Tue, 3 Feb 2015 21:10:58 +0300 Subject: [PATCH] Create from usage: make new member function/property private by default #KT-6689 Fixed --- .../callableBuilder/CallableBuilder.kt | 10 ++++++++-- .../createFunction/call/afterMemberFunNoReceiver.kt | 2 +- .../call/afterMemberValDelegateRuntime.kt | 2 +- .../call/afterMemberVarDelegateRuntime.kt | 2 +- .../call/afterObjectMemberFunNoReceiver.kt | 2 +- .../createFunction/call/afterPrivateForMembers.kt | 10 ++++++++++ .../createFunction/call/afterThisInClass.kt | 2 +- .../createFunction/call/afterThisInNestedClass1.kt | 2 +- .../createFunction/call/afterThisInNestedClass2.kt | 2 +- .../createFunction/call/beforePrivateForMembers.kt | 6 ++++++ .../createFunction/get/afterCreateGetFromUsage1.kt | 2 +- .../createFunction/get/afterCreateGetFromUsage10.kt | 2 +- .../createFunction/get/afterCreateGetFromUsage13.kt | 2 +- .../createFunction/get/afterCreateGetFromUsage3.kt | 2 +- .../createFunction/get/afterCreateGetFromUsage4.kt | 2 +- .../createFunction/get/afterCreateGetFromUsage5.kt | 2 +- .../createFunction/get/afterCreateGetFromUsage7.kt | 2 +- .../createFunction/get/afterCreateGetFromUsage8.kt | 2 +- .../createFunction/get/afterCreateGetFromUsage9.kt | 2 +- .../createFunction/set/afterCreateSetFromUsage1.kt | 2 +- .../property/afterMemberValDelegateRuntime.kt | 2 +- .../property/afterMemberValNoReceiver.kt | 2 +- .../property/afterMemberVarDelegateRuntime.kt | 2 +- .../property/afterObjectMemberValNoReceiver.kt | 2 +- .../property/afterPrivateForMembers.kt | 9 +++++++++ .../createVariable/property/afterThisInClass.kt | 2 +- .../property/afterThisInNestedClass1.kt | 2 +- .../property/afterThisInNestedClass2.kt | 2 +- .../property/beforePrivateForMembers.kt | 7 +++++++ .../kotlin/idea/quickfix/QuickFixTestGenerated.java | 12 ++++++++++++ 30 files changed, 76 insertions(+), 26 deletions(-) create mode 100644 idea/testData/quickfix/createFromUsage/createFunction/call/afterPrivateForMembers.kt create mode 100644 idea/testData/quickfix/createFromUsage/createFunction/call/beforePrivateForMembers.kt create mode 100644 idea/testData/quickfix/createFromUsage/createVariable/property/afterPrivateForMembers.kt create mode 100644 idea/testData/quickfix/createFromUsage/createVariable/property/beforePrivateForMembers.kt diff --git a/idea/src/org/jetbrains/kotlin/idea/quickfix/createFromUsage/callableBuilder/CallableBuilder.kt b/idea/src/org/jetbrains/kotlin/idea/quickfix/createFromUsage/callableBuilder/CallableBuilder.kt index 609ccb53a96..de827bb9489 100644 --- a/idea/src/org/jetbrains/kotlin/idea/quickfix/createFromUsage/callableBuilder/CallableBuilder.kt +++ b/idea/src/org/jetbrains/kotlin/idea/quickfix/createFromUsage/callableBuilder/CallableBuilder.kt @@ -72,6 +72,7 @@ import com.intellij.openapi.editor.LogicalPosition import com.intellij.openapi.editor.actions.EditorActionUtil import com.intellij.openapi.editor.actions.LineEndAction import com.intellij.openapi.editor.actions.EnterAction +import org.jetbrains.kotlin.psi.psiUtil.isAncestor private val TYPE_PARAMETER_LIST_VARIABLE_NAME = "typeParameterList" private val TEMPLATE_FROM_USAGE_FUNCTION_BODY = "New Kotlin Function Body.kt" @@ -392,8 +393,13 @@ class CallableBuilder(val config: CallableBuilderConfiguration) { val psiFactory = JetPsiFactory(currentFile) + val modifiers = + if (containingElement is JetClassOrObject && containingElement.isAncestor(config.originalElement)) + "private " + else "" + val declaration : JetNamedDeclaration = when (callableInfo.kind) { - CallableKind.FUNCTION -> psiFactory.createFunction("fun<> $header {}") + CallableKind.FUNCTION -> psiFactory.createFunction("${modifiers}fun<> $header {}") CallableKind.CONSTRUCTOR -> { with((callableInfo as ConstructorInfo).classInfo) { val classBody = when (kind) { @@ -422,7 +428,7 @@ class CallableBuilder(val config: CallableBuilderConfiguration) { } CallableKind.PROPERTY -> { val valVar = if ((callableInfo as PropertyInfo).writable) "var" else "val" - psiFactory.createProperty("$valVar<> $header") + psiFactory.createProperty("$modifiers$valVar<> $header") } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberFunNoReceiver.kt b/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberFunNoReceiver.kt index 7808656417f..a0c87743d65 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberFunNoReceiver.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberFunNoReceiver.kt @@ -6,7 +6,7 @@ class A { return foo(2, "2") } - fun foo(i: Int, s: String): Int { + private fun foo(i: Int, s: String): Int { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberValDelegateRuntime.kt b/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberValDelegateRuntime.kt index a9e82bb7a4c..b592d84b8f2 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberValDelegateRuntime.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberValDelegateRuntime.kt @@ -5,7 +5,7 @@ import kotlin.properties.ReadOnlyProperty class A(val t: T) { val x: A by foo(t, "") - fun foo(t: T, s: String): ReadOnlyProperty, A> { + private fun foo(t: T, s: String): ReadOnlyProperty, A> { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberVarDelegateRuntime.kt b/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberVarDelegateRuntime.kt index faf540b5a93..2e57d442f10 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberVarDelegateRuntime.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/call/afterMemberVarDelegateRuntime.kt @@ -5,7 +5,7 @@ import kotlin.properties.ReadWriteProperty class A(val t: T) { var x: A by foo(t, "") - fun foo(t: T, s: String): ReadWriteProperty, A> { + private fun foo(t: T, s: String): ReadWriteProperty, A> { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/call/afterObjectMemberFunNoReceiver.kt b/idea/testData/quickfix/createFromUsage/createFunction/call/afterObjectMemberFunNoReceiver.kt index 45476ab0623..ff3e9b09417 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/call/afterObjectMemberFunNoReceiver.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/call/afterObjectMemberFunNoReceiver.kt @@ -6,7 +6,7 @@ class A { return foo(2, "2") } - fun foo(i: Int, s: String): Int { + private fun foo(i: Int, s: String): Int { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/call/afterPrivateForMembers.kt b/idea/testData/quickfix/createFromUsage/createFunction/call/afterPrivateForMembers.kt new file mode 100644 index 00000000000..24a0e1fafdf --- /dev/null +++ b/idea/testData/quickfix/createFromUsage/createFunction/call/afterPrivateForMembers.kt @@ -0,0 +1,10 @@ +// "Create function 'foo'" "true" +class A { + fun test() { + foo() + } + + private fun foo() { + throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. + } +} \ No newline at end of file diff --git a/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInClass.kt b/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInClass.kt index c10600b4a0a..f25c3d6af4d 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInClass.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInClass.kt @@ -5,7 +5,7 @@ class A(val n: T) { return this.foo(2, "2") } - fun foo(i: Int, s: String): A { + private fun foo(i: Int, s: String): A { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } \ No newline at end of file diff --git a/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInNestedClass1.kt b/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInNestedClass1.kt index 3f0c29210df..a8804dece89 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInNestedClass1.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInNestedClass1.kt @@ -6,7 +6,7 @@ class A(val n: T) { return this.foo(2, "2") } - fun foo(i: Int, s: String): A { + private fun foo(i: Int, s: String): A { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInNestedClass2.kt b/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInNestedClass2.kt index b96ede9650c..aaff9e7690f 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInNestedClass2.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/call/afterThisInNestedClass2.kt @@ -7,7 +7,7 @@ class A(val n: T) { } } - fun foo(i: Int, s: String): A { + private fun foo(i: Int, s: String): A { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } \ No newline at end of file diff --git a/idea/testData/quickfix/createFromUsage/createFunction/call/beforePrivateForMembers.kt b/idea/testData/quickfix/createFromUsage/createFunction/call/beforePrivateForMembers.kt new file mode 100644 index 00000000000..649efb0b115 --- /dev/null +++ b/idea/testData/quickfix/createFromUsage/createFunction/call/beforePrivateForMembers.kt @@ -0,0 +1,6 @@ +// "Create function 'foo'" "true" +class A { + fun test() { + foo() + } +} \ No newline at end of file diff --git a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage1.kt b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage1.kt index 26dfb980eb1..03737856bc6 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage1.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage1.kt @@ -4,7 +4,7 @@ class Foo { val z: Iterable = y[""] } - fun get(s: String): T { + private fun get(s: String): T { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage10.kt b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage10.kt index a30586b7726..bef90bafc40 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage10.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage10.kt @@ -4,7 +4,7 @@ class Foo { val z: Iterable = y["", w] } - fun get(s: String, w: T): T { + private fun get(s: String, w: T): T { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage13.kt b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage13.kt index 343511ab17b..f3a7397a9d5 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage13.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage13.kt @@ -8,7 +8,7 @@ class Foo { bar(z) } - fun get(s: String, w: ArrayList): String { + private fun get(s: String, w: ArrayList): String { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage3.kt b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage3.kt index c75350f814f..f4fa4103830 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage3.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage3.kt @@ -4,7 +4,7 @@ class Foo { val z: Iterable = y[""] } - fun get(s: String): T { + private fun get(s: String): T { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage4.kt b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage4.kt index 9dc4b33ddd5..4dd9d81c6cd 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage4.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage4.kt @@ -4,7 +4,7 @@ class Foo> { val z: U = y[""] } - fun get(s: String): T { + private fun get(s: String): T { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage5.kt b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage5.kt index f4ec2b9d3fa..e7804794ed8 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage5.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage5.kt @@ -4,7 +4,7 @@ class Foo { val z: Iterable = y["", w] } - fun get(s: String, w: Iterable): T { + private fun get(s: String, w: Iterable): T { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage7.kt b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage7.kt index b29cec493b4..b040522fa77 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage7.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage7.kt @@ -6,7 +6,7 @@ class Foo { val z: Iterable = y["", w, v] } - fun get(s: String, w: ArrayList, v: T1): T { + private fun get(s: String, w: ArrayList, v: T1): T { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage8.kt b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage8.kt index 66a9cacdd9f..db3c4c9e888 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage8.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage8.kt @@ -6,7 +6,7 @@ class Foo { val z: Iterable = y["", w] } - fun get(s: String, w: T): T { + private fun get(s: String, w: T): T { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage9.kt b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage9.kt index 13f946eae33..3e71c1e59f0 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage9.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/get/afterCreateGetFromUsage9.kt @@ -6,7 +6,7 @@ class Foo { val z: Iterable = y["", w] } - fun get(s: String, w: S): S { + private fun get(s: String, w: S): S { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createFunction/set/afterCreateSetFromUsage1.kt b/idea/testData/quickfix/createFromUsage/createFunction/set/afterCreateSetFromUsage1.kt index 36c03cb63ce..3efa7201947 100644 --- a/idea/testData/quickfix/createFromUsage/createFunction/set/afterCreateSetFromUsage1.kt +++ b/idea/testData/quickfix/createFromUsage/createFunction/set/afterCreateSetFromUsage1.kt @@ -4,7 +4,7 @@ class Foo { y["", w] = w } - fun set(s: String, w: T, value: T) { + private fun set(s: String, w: T, value: T) { throw UnsupportedOperationException("not implemented") //To change body of created functions use File | Settings | File Templates. } } diff --git a/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberValDelegateRuntime.kt b/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberValDelegateRuntime.kt index 1e8941d6c09..902cd133c5f 100644 --- a/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberValDelegateRuntime.kt +++ b/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberValDelegateRuntime.kt @@ -5,6 +5,6 @@ import kotlin.properties.ReadOnlyProperty class A { - val foo: ReadOnlyProperty, A> + private val foo: ReadOnlyProperty, A> val x: A by foo } diff --git a/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberValNoReceiver.kt b/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberValNoReceiver.kt index 0015e0c9f65..cab91bf8673 100644 --- a/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberValNoReceiver.kt +++ b/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberValNoReceiver.kt @@ -3,7 +3,7 @@ class A { class B { - val foo: Int + private val foo: Int fun test(): Int { return foo diff --git a/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberVarDelegateRuntime.kt b/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberVarDelegateRuntime.kt index 920588f4507..beb5231e298 100644 --- a/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberVarDelegateRuntime.kt +++ b/idea/testData/quickfix/createFromUsage/createVariable/property/afterMemberVarDelegateRuntime.kt @@ -5,6 +5,6 @@ import kotlin.properties.ReadWriteProperty class A { - val foo: ReadWriteProperty, A> + private val foo: ReadWriteProperty, A> var x: A by foo } diff --git a/idea/testData/quickfix/createFromUsage/createVariable/property/afterObjectMemberValNoReceiver.kt b/idea/testData/quickfix/createFromUsage/createVariable/property/afterObjectMemberValNoReceiver.kt index 62009e2a2d1..38b0f69c9c3 100644 --- a/idea/testData/quickfix/createFromUsage/createVariable/property/afterObjectMemberValNoReceiver.kt +++ b/idea/testData/quickfix/createFromUsage/createVariable/property/afterObjectMemberValNoReceiver.kt @@ -3,7 +3,7 @@ class A { object B { - val foo: Int + private val foo: Int fun test(): Int { return foo diff --git a/idea/testData/quickfix/createFromUsage/createVariable/property/afterPrivateForMembers.kt b/idea/testData/quickfix/createFromUsage/createVariable/property/afterPrivateForMembers.kt new file mode 100644 index 00000000000..34d935df0e4 --- /dev/null +++ b/idea/testData/quickfix/createFromUsage/createVariable/property/afterPrivateForMembers.kt @@ -0,0 +1,9 @@ +// "Create property 'foo'" "true" +// ERROR: Property must be initialized or be abstract +class A { + private var foo: Int + + fun test() { + foo = 1 + } +} \ No newline at end of file diff --git a/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInClass.kt b/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInClass.kt index b6d388c4177..1701d58dbdf 100644 --- a/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInClass.kt +++ b/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInClass.kt @@ -2,7 +2,7 @@ // ERROR: Property must be initialized or be abstract class A(val n: T) { - val foo: A + private val foo: A fun test(): A { return this.foo diff --git a/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInNestedClass1.kt b/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInNestedClass1.kt index dc3f5254d36..32734ae2e4a 100644 --- a/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInNestedClass1.kt +++ b/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInNestedClass1.kt @@ -3,7 +3,7 @@ class A(val n: T) { inner class B(val m: U) { - val foo: A + private val foo: A fun test(): A { return this.foo diff --git a/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInNestedClass2.kt b/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInNestedClass2.kt index 9736b116714..62f9c43a7a5 100644 --- a/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInNestedClass2.kt +++ b/idea/testData/quickfix/createFromUsage/createVariable/property/afterThisInNestedClass2.kt @@ -2,7 +2,7 @@ // ERROR: Property must be initialized or be abstract class A(val n: T) { - val foo: A + private val foo: A inner class B(val m: U) { fun test(): A { diff --git a/idea/testData/quickfix/createFromUsage/createVariable/property/beforePrivateForMembers.kt b/idea/testData/quickfix/createFromUsage/createVariable/property/beforePrivateForMembers.kt new file mode 100644 index 00000000000..4f41d28b071 --- /dev/null +++ b/idea/testData/quickfix/createFromUsage/createVariable/property/beforePrivateForMembers.kt @@ -0,0 +1,7 @@ +// "Create property 'foo'" "true" +// ERROR: Property must be initialized or be abstract +class A { + fun test() { + foo = 1 + } +} \ No newline at end of file diff --git a/idea/tests/org/jetbrains/kotlin/idea/quickfix/QuickFixTestGenerated.java b/idea/tests/org/jetbrains/kotlin/idea/quickfix/QuickFixTestGenerated.java index e46e66484d9..6e1a8ffb234 100644 --- a/idea/tests/org/jetbrains/kotlin/idea/quickfix/QuickFixTestGenerated.java +++ b/idea/tests/org/jetbrains/kotlin/idea/quickfix/QuickFixTestGenerated.java @@ -1660,6 +1660,12 @@ public class QuickFixTestGenerated extends AbstractQuickFixTest { doTest(fileName); } + @TestMetadata("beforePrivateForMembers.kt") + public void testPrivateForMembers() throws Exception { + String fileName = JetTestUtils.navigationMetadata("idea/testData/quickfix/createFromUsage/createFunction/call/beforePrivateForMembers.kt"); + doTest(fileName); + } + @TestMetadata("beforePropertyOnUserType.kt") public void testPropertyOnUserType() throws Exception { String fileName = JetTestUtils.navigationMetadata("idea/testData/quickfix/createFromUsage/createFunction/call/beforePropertyOnUserType.kt"); @@ -2519,6 +2525,12 @@ public class QuickFixTestGenerated extends AbstractQuickFixTest { doTest(fileName); } + @TestMetadata("beforePrivateForMembers.kt") + public void testPrivateForMembers() throws Exception { + String fileName = JetTestUtils.navigationMetadata("idea/testData/quickfix/createFromUsage/createVariable/property/beforePrivateForMembers.kt"); + doTest(fileName); + } + @TestMetadata("beforeThisInClass.kt") public void testThisInClass() throws Exception { String fileName = JetTestUtils.navigationMetadata("idea/testData/quickfix/createFromUsage/createVariable/property/beforeThisInClass.kt");