下面列出了org.junit.internal.TextListener#junit.runner.Version 实例代码,或者点击链接到github查看源代码,也可以在右侧发表评论。
/**
* Returns a new {@link RunListener} instance for the given {@param outputFormat}.
*/
public RunListener newRunListener(OutputFormat outputFormat) {
switch (outputFormat) {
case JUNIT:
out.println("JUnit version " + Version.id());
return new TextListener(out);
case GTM_UNIT_TESTING:
return new GtmUnitTestingTextListener();
default:
throw new IllegalArgumentException("outputFormat");
}
}
/**
* Returns a new {@link RunListener} instance for the given {@param outputFormat}.
*/
public RunListener newRunListener(OutputFormat outputFormat) {
switch (outputFormat) {
case JUNIT:
out.println("JUnit version " + Version.id());
return new TextListener(out);
case GTM_UNIT_TESTING:
return new GtmUnitTestingTextListener();
default:
throw new IllegalArgumentException("outputFormat");
}
}
/**
* @return the version number of this release
*/
public String getVersion() {
return Version.id();
}
@Override
@Before
public void initializeLogResultsToConsoleValue() {
ValidationLogger.logResults = LOG_RESULTS_TO_CONSOLE;
println("JUnit version: " + Version.id());
}