Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
test: Adjust log messages for consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
seanf committed Mar 3, 2016
1 parent dd00d25 commit e5c1978
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
Expand Up @@ -75,7 +75,7 @@ private String getTestDescription() {

@Before
public final void testEntry() {
log.info("Starting ".concat(getTestDescription()));
log.info("Test starting: {}", getTestDescription());
testFunctionStart = new DateTime();
WebDriverFactory.INSTANCE.testEntry();
zanataRestCaller.signalBeforeTest(getClass().getName(), testName.getMethodName());
Expand All @@ -87,8 +87,8 @@ public final void testExit() {
zanataRestCaller.signalAfterTest(getClass().getName(), testName.getMethodName());
Duration duration = new Duration(testFunctionStart, new DateTime());
PeriodFormatter periodFormatter = new PeriodFormatterBuilder()
.appendLiteral("Finished "
.concat(getTestDescription()).concat(" in "))
.appendLiteral("Test finished: "
.concat(getTestDescription()).concat(": in "))
.printZeroAlways()
.appendMinutes()
.appendSuffix(" minutes, ")
Expand Down
18 changes: 9 additions & 9 deletions functional-test/src/test/java/org/zanata/util/TestLogger.java
Expand Up @@ -34,28 +34,28 @@
public class TestLogger extends RunListener {
@Override
public void testStarted(Description description) throws Exception {
log.info("Test {} starting", description);
log.info("Test starting: {}", description);
}

@Override
public void testFinished(Description description) throws Exception {
log.info("Test {} finished", description);
log.info("Test finished: {}", description);
}

@Override
public void testFailure(Failure failure) throws Exception {
log.error("FAILED test " + failure, failure.getException());
public void testIgnored(Description description) throws Exception {
log.error("Test IGNORED: {}", description);
}

@Override
public void testAssumptionFailure(Failure failure) {
log.error("FAILED ASSUMPTION in test " + failure,
failure.getException());
public void testFailure(Failure failure) throws Exception {
log.error("Test FAILED: " + failure, failure.getException());
}

@Override
public void testIgnored(Description description) throws Exception {
log.error("Test {} IGNORED", description);
public void testAssumptionFailure(Failure failure) {
log.error("Test FAILED ASSUMPTION: " + failure,
failure.getException());
}

}

0 comments on commit e5c1978

Please sign in to comment.