This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Product Version = NetBeans IDE Dev (Build 201510070002) Operating System = Windows 7 version 6.1 running on amd64 Java; VM; Vendor = 1.8.0_66-ea Runtime = Java HotSpot(TM) 64-Bit Server VM 25.66-b02 Reproducibility: Happens every time STEPS: * Create a new project from: samples\groovy\NB-Project-Generators * Add a new Groovy class project with name "Foo" and package name "test" * add a method to Foo class named bar: void bar() { println "foobar" } * add a new Groovy script to project, test package * add these lines: c = new Foo() c.bar(); * don't save file,... and switch back to Foo class * select Foo class from project window, and hit ctrl+R to invoke refactor-rename, provide a new name for it like "FooRenamed", and confirm refactor * switch back to groovy script file, notice that rename took place,... then press Ctrl+Z to invoke undo, and confirm ACTUAL: FooRenamed class gets renamed back to Foo, and change is reflected also in the script file. However, name of class will not get renamed back to "Foo",... instead stays "FooRenamed", causing compilation error in the script file where it is used. EXPECTED: Undoing the refactor task should also rename back the affected class file nam
Thank you for reporting this. After executing the test case provided I found it to be accurate: When reverting the rename class operation the file name is not reverted. I've found no difference with respect to the sixth step, i.e: The incorrect behaviour prevailed whether I saved the files or left them in the unsaved state.