x/tools/cmd/gorename: unsure how to use -from to specify renaming test #34659
Labels
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Refactoring
Issues related to refactoring tools
Tools
This label describes issues relating to any tools in the x/tools repository.
Milestone
What did you do?
Created a simple package "foo" in $GOPATH/src/foo with a single go file foo_test.go:
I can successfully rename testVal using the -offset option:
However I cannot seem to use the -from option because it fails to find the package:
What did you expect to see?
I expect to see gorename succeed when using -from on a test package.
I've tried a
foo.go
containing similar code under package foo, and renaming the symbol using gorename -from is fine.I'm not sure if I need to specify some kind of testing build tag using the -tags option to get it to examine test packages.
The text was updated successfully, but these errors were encountered: