-
Notifications
You must be signed in to change notification settings - Fork 18.4k
Closed
Labels
FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.ToolsThis label describes issues relating to any tools in the x/tools repository.This label describes issues relating to any tools in the x/tools repository.
Milestone
Description
Suppose you run analysistest.Run
on a package with a test file (say to test test-specific behavior of the analyzer). What apparently happens is that analysistest calls the analyzer once on the package without its tests, and once on the package with its tests. This is not a big deal; you get some duplicate error messages.
But now suppose you instead run analysistest.RunWithSuggestedFixes
. In this case, analysistest ends up combining the fixes from both runs. This means you get all your fixes applied twice, which surely doesn't match your .golden
file! it's a very confusing error.
A workaround is to change the test file to mypackage_test
, such that the two runs will be entirely disjoint.
Metadata
Metadata
Assignees
Labels
FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.ToolsThis label describes issues relating to any tools in the x/tools repository.This label describes issues relating to any tools in the x/tools repository.