Rename: add test for overridden method renaming in generic class
#KT-26047 Fixed
This commit is contained in:
committed by
igoriakovlev
parent
ff76ba52d8
commit
cb1c0344b8
+12
@@ -0,0 +1,12 @@
|
||||
package test
|
||||
|
||||
open class A<T> {
|
||||
open fun bar() {
|
||||
}
|
||||
}
|
||||
|
||||
class B<T> : A<T>() {
|
||||
override fun bar() {
|
||||
super.bar()
|
||||
}
|
||||
}
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
package test
|
||||
|
||||
open class A<T> {
|
||||
open fun foo() {
|
||||
}
|
||||
}
|
||||
|
||||
class B<T> : A<T>() {
|
||||
override fun foo() {
|
||||
super.foo()
|
||||
}
|
||||
}
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"type": "KOTLIN_FUNCTION",
|
||||
"classId": "test/A",
|
||||
"oldName": "foo",
|
||||
"newName": "bar"
|
||||
}
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"type": "KOTLIN_FUNCTION",
|
||||
"classId": "test/B",
|
||||
"oldName": "foo",
|
||||
"newName": "bar"
|
||||
}
|
||||
+10
@@ -813,6 +813,16 @@ public class RenameTestGenerated extends AbstractRenameTest {
|
||||
runTest("idea/testData/refactoring/rename/renameKotlinFunctionInEnum/renameKotlinFunctionInEnumFromSubclass.test");
|
||||
}
|
||||
|
||||
@TestMetadata("renameKotlinFunctionInGenericClass/renameKotlinFunctionInGenericClass.test")
|
||||
public void testRenameKotlinFunctionInGenericClass_RenameKotlinFunctionInGenericClass() throws Exception {
|
||||
runTest("idea/testData/refactoring/rename/renameKotlinFunctionInGenericClass/renameKotlinFunctionInGenericClass.test");
|
||||
}
|
||||
|
||||
@TestMetadata("renameKotlinFunctionInGenericClass/renameKotlinFunctionInGenericClassFromSubclass.test")
|
||||
public void testRenameKotlinFunctionInGenericClass_RenameKotlinFunctionInGenericClassFromSubclass() throws Exception {
|
||||
runTest("idea/testData/refactoring/rename/renameKotlinFunctionInGenericClass/renameKotlinFunctionInGenericClassFromSubclass.test");
|
||||
}
|
||||
|
||||
@TestMetadata("renameKotlinFunctionParameterWithByNameUsages/renameKotlinFunctionParameterWithByNameUsages.test")
|
||||
public void testRenameKotlinFunctionParameterWithByNameUsages_RenameKotlinFunctionParameterWithByNameUsages() throws Exception {
|
||||
runTest("idea/testData/refactoring/rename/renameKotlinFunctionParameterWithByNameUsages/renameKotlinFunctionParameterWithByNameUsages.test");
|
||||
|
||||
Reference in New Issue
Block a user