Skip to content

Commit

Permalink
Fix Java 5 compilation problem.
Browse files Browse the repository at this point in the history
Remove @OverRide from compare(Method, Method) because Java 5 doesn't
support @OverRide for implementations of interface methods. You need
Java 6 for this.
  • Loading branch information
stefanbirkner committed Feb 28, 2012
1 parent 59c686f commit 84fd87b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/org/junit/internal/MethodSorter.java
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public class MethodSorter {
public static Method[] getDeclaredMethods(Class<?> clazz) {
Method[] methods = clazz.getDeclaredMethods();
Arrays.sort(methods, new Comparator<Method>() {
@Override public int compare(Method m1, Method m2) {
public int compare(Method m1, Method m2) {
int i1 = m1.getName().hashCode();
int i2 = m2.getName().hashCode();
return i1 != i2 ? i1 - i2 : m1.toString().compareTo(m2.toString());
Expand Down

0 comments on commit 84fd87b

Please sign in to comment.