File tree Expand file tree Collapse file tree 1 file changed +25
-0
lines changed
core/src/test/java/com/google/errorprone/bugpatterns Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Original file line number Diff line number Diff line change @@ -1655,4 +1655,29 @@ public void unusedFunctionalInterfaceParameter_noFix() {
1655
1655
.expectUnchanged ()
1656
1656
.doTest ();
1657
1657
}
1658
+
1659
+ @ Ignore ("https://github.com/google/error-prone/issues/4409" )
1660
+ @ Test
1661
+ public void parameterUsedInOverride () {
1662
+ refactoringHelper
1663
+ .addInputLines (
1664
+ "App.java" ,
1665
+ "public class App {" ,
1666
+ " private static class Base {" ,
1667
+ " protected void doStuff(String usedInDescendants) {}" ,
1668
+ " }" ,
1669
+ " private static class Descendant extends Base {" ,
1670
+ " @Override" ,
1671
+ " protected void doStuff(String actuallyUsed) {" ,
1672
+ " System.out.println(actuallyUsed);" ,
1673
+ " }" ,
1674
+ " }" ,
1675
+ " public static void main(String[] args) {" ,
1676
+ " Base b = new Descendant();" ,
1677
+ " b.doStuff(\" some string\" );" ,
1678
+ " }" ,
1679
+ "}" )
1680
+ .expectUnchanged ()
1681
+ .doTest ();
1682
+ }
1658
1683
}
You can’t perform that action at this time.
0 commit comments