Methods Summary |
---|
private boolean | hasBuildListenerEvents(java.lang.String log)
return log.indexOf(JUnitTask.TESTLISTENER_PREFIX) >= 0;
|
private boolean | hasEventMessage(java.lang.String eventPrefix)
return getFullLog().indexOf(eventPrefix) >= 0;
|
public void | setUp()
configureProject("src/etc/testcases/taskdefs/optional/junit.xml");
|
public void | testEndTestFired()
executeTarget(PASS_TEST_TARGET);
assertTrue("expecting test ended message",
hasEventMessage(JUnitTask.TESTLISTENER_PREFIX +
"endTest(" + PASS_TEST + ")"));
|
public void | testFullLogOutput()
executeTarget(PASS_TEST_TARGET);
assertTrue("expecting full log to have BuildListener events",
hasBuildListenerEvents(getFullLog()));
|
public void | testNoLogOutput()
executeTarget(PASS_TEST_TARGET);
assertFalse("expecting log to not have BuildListener events",
hasBuildListenerEvents(getLog()));
|
public void | testStartTestFired()
executeTarget(PASS_TEST_TARGET);
assertTrue("expecting test started message",
hasEventMessage(JUnitTask.TESTLISTENER_PREFIX +
"startTest(" + PASS_TEST + ")"));
|
public void | testTestCountFired()
executeTarget(PASS_TEST_TARGET);
assertTrue("expecting test count message",
hasEventMessage(JUnitTask.TESTLISTENER_PREFIX +
"tests to run: "));
|