Skip to content

Commit ff8ef0b

Browse files
martinkretzschmartomball
authored andcommitted
Stop using class name heuristics to filter out non-tests.
The bug that made that necessary has been fixed by now. Change on 2018/04/18 by mkretzschmar <[email protected]> ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=193361163
1 parent d0fc14c commit ff8ef0b

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

testing/junit_ext/src/java/com/google/j2objc/testing/JUnitTestRunner.java

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@
3838
import org.junit.runner.RunWith;
3939
import org.junit.runner.notification.Failure;
4040
import org.junit.runner.notification.RunListener;
41-
import org.junit.runners.JUnit4;
4241
import org.junit.runners.Suite;
4342

4443
/*-[
@@ -259,15 +258,8 @@ protected boolean isJUnit3TestClass(Class<?> cls) {
259258
return false;
260259
}
261260

262-
/**
263-
* @return true if {@param cls} is {@link JUnit4} annotated.
264-
*/
261+
/** @return true if {@param cls} is {@link RunWith} annotated. */
265262
protected boolean isJUnit4TestClass(Class<?> cls) {
266-
// Need to find test classes, otherwise crashes with b/11790448.
267-
if (!cls.getName().endsWith("Test")) {
268-
return false;
269-
}
270-
// Check the annotation.
271263
return cls.getAnnotation(RunWith.class) != null;
272264
}
273265

0 commit comments

Comments
 (0)