Java 类org.junit.internal.builders.SuiteMethodBuilder 实例源码
项目:intellij-ce-playground
文件:JUnit46ClassesRequestBuilder.java
private static List collectWrappedRunners(Class[] classes) throws InitializationError {
final List runners = new ArrayList();
final List nonSuiteClasses = new ArrayList();
final SuiteMethodBuilder suiteMethodBuilder = new SuiteMethodBuilder();
for (int i = 0, length = classes.length; i < length; i++) {
Class aClass = classes[i];
if (suiteMethodBuilder.hasSuiteMethod(aClass)) {
try {
runners.add(new ClassAwareSuiteMethod(aClass));
}
catch (Throwable throwable) {
runners.add(new ErrorReportingRunner(aClass, throwable));
}
} else {
nonSuiteClasses.add(aClass);
}
}
runners.addAll(new AllDefaultPossibilitiesBuilder(false).runners(null, (Class[])nonSuiteClasses.toArray(new Class[nonSuiteClasses.size()])));
return runners;
}
项目:tools-idea
文件:JUnit46ClassesRequestBuilder.java
private static List collectWrappedRunners(Class[] classes) throws InitializationError {
final List runners = new ArrayList();
final List nonSuiteClasses = new ArrayList();
final SuiteMethodBuilder suiteMethodBuilder = new SuiteMethodBuilder();
for (int i = 0, length = classes.length; i < length; i++) {
Class aClass = classes[i];
if (suiteMethodBuilder.hasSuiteMethod(aClass)) {
try {
runners.add(new ClassAwareSuiteMethod(aClass));
}
catch (Throwable throwable) {
runners.add(new ErrorReportingRunner(aClass, throwable));
}
} else {
nonSuiteClasses.add(aClass);
}
}
runners.addAll(new AllDefaultPossibilitiesBuilder(false).runners(null, (Class[])nonSuiteClasses.toArray(new Class[nonSuiteClasses.size()])));
return runners;
}
项目:sosiefier
文件:ClassRequestTest.java
@Test
public void noSuiteMethodIfMethodPrivate() throws Throwable {
assertNull(new SuiteMethodBuilder()
.runnerForClass(PrivateSuiteMethod.class));
}
项目:junit
文件:ClassRequestTest.java
@Test
public void noSuiteMethodIfMethodPrivate() throws Throwable {
assertNull(new SuiteMethodBuilder()
.runnerForClass(PrivateSuiteMethod.class));
}
项目:health-and-care-developer-network
文件:ClassRequestTest.java
@Test
public void noSuiteMethodIfMethodPrivate() throws Throwable {
assertNull(new SuiteMethodBuilder()
.runnerForClass(PrivateSuiteMethod.class));
}