Skip to content

Commit 7aaed94

Browse files
klueverError Prone Team
authored andcommitted
Discourage use of JUnit3 via static analysis.
Putting this in `JdkObsolete` is a bit of a hack, but we already have non-JDK APIs in there (`org.apache.commons.io.IOUtils`), so... PiperOrigin-RevId: 908153869
1 parent 42c93df commit 7aaed94

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

core/src/main/java/com/google/errorprone/bugpatterns/JdkObsolete.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,8 @@ Optional<Fix> fix(Tree tree, VisitorState state) {
152152
"Dictionary is a nonstandard class that predates the Java Collections Framework;"
153153
+ " use LinkedHashMap."),
154154
new Obsolete(
155-
"java.util.Enumeration", "Enumeration is an ancient precursor to Iterator."))
155+
"java.util.Enumeration", "Enumeration is an ancient precursor to Iterator."),
156+
new Obsolete("junit.framework.TestCase", "JUnit3 is obsolete; use JUnit4 instead."))
156157
.stream()
157158
.collect(toImmutableMap(Obsolete::qualifiedName, x -> x));
158159

0 commit comments

Comments
 (0)