public Runner buildRunner(Class<? extends Runner> runnerClass) {
try {
return runnerClass.getConstructor(Class.class).newInstance(new Object[] { fTestClass });
} catch (NoSuchMethodException e) {
String simpleName= runnerClass.getSimpleName();
InitializationError error= new InitializationError(String.format(
CONSTRUCTOR_ERROR_FORMAT, simpleName, simpleName));
return Request.errorReport(fTestClass, error).getRunner();
} catch (Exception e) {
return Request.errorReport(fTestClass, e).getRunner();
}