jsystem.framework.report
Class ListenerstManager

java.lang.Object
  extended byjsystem.framework.report.ListenerstManager
All Implemented Interfaces:
FixtureListener, Reporter, TestListener

public class ListenerstManager
extends Object
implements TestListener, FixtureListener, Reporter

Manage the listeners in the framework: TestListener FixtureListener TestReporter


Method Summary
 void aboutToChangeTo(Fixture fixture)
          Will be called before the execution of the fixture.
 void addError(Test test, Throwable t)
           
 void addFailure(Test test, AssertionFailedError t)
           
 void addListener(Object listener)
           
 void endFixturring()
          Is called after the fixture navigation ends.
 void endTest(Test test)
           
 void fixtureChanged(Fixture fixture)
          Will be called after the execution of the fixture.
 ArrayList getAllReporters()
           
static ListenerstManager getInstance()
           
 void removeListener(Object listener)
           
 void report(String title)
          Post a test report
 void report(String title, boolean status)
          Post a test report
 void report(String title, String message, boolean status)
          Post a test report
 void report(String title, String message, boolean status, boolean bold)
          Post a test report
 void report(String title, Throwable t)
          Post a test failer report.
 void startFixturring()
          Is called before the fixture navigation is started.
 void startTest(Test test)
           
 void step(String stepDiscription)
          Post a step report
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

addListener

public void addListener(Object listener)

removeListener

public void removeListener(Object listener)

getInstance

public static ListenerstManager getInstance()

report

public void report(String title,
                   String message,
                   boolean status)
Description copied from interface: Reporter
Post a test report

Specified by:
report in interface Reporter
Parameters:
title - Report title.
message - Report message.
status - report status.

report

public void report(String title,
                   String message,
                   boolean status,
                   boolean bold)
Description copied from interface: Reporter
Post a test report

Specified by:
report in interface Reporter
Parameters:
title - Report title.
message - Report message.
status - report status.
bold - bold report.

report

public void report(String title,
                   boolean status)
Description copied from interface: Reporter
Post a test report

Specified by:
report in interface Reporter
Parameters:
title - Report title.
status - report status.

report

public void report(String title)
Description copied from interface: Reporter
Post a test report

Specified by:
report in interface Reporter
Parameters:
title - Report title.

step

public void step(String stepDiscription)
Description copied from interface: Reporter
Post a step report

Specified by:
step in interface Reporter
Parameters:
stepDiscription - Step discription.

report

public void report(String title,
                   Throwable t)
Description copied from interface: Reporter
Post a test failer report.

Specified by:
report in interface Reporter
Parameters:
title - Test title.
t - The exception that cause the report.

addError

public void addError(Test test,
                     Throwable t)
Specified by:
addError in interface TestListener

addFailure

public void addFailure(Test test,
                       AssertionFailedError t)
Specified by:
addFailure in interface TestListener

endTest

public void endTest(Test test)
Specified by:
endTest in interface TestListener

startTest

public void startTest(Test test)
Specified by:
startTest in interface TestListener

aboutToChangeTo

public void aboutToChangeTo(Fixture fixture)
Description copied from interface: FixtureListener
Will be called before the execution of the fixture.

Specified by:
aboutToChangeTo in interface FixtureListener
Parameters:
fixture - The fixture that is going to be executed.

fixtureChanged

public void fixtureChanged(Fixture fixture)
Description copied from interface: FixtureListener
Will be called after the execution of the fixture.

Specified by:
fixtureChanged in interface FixtureListener
Parameters:
fixture - The fixture that was executed.

startFixturring

public void startFixturring()
Description copied from interface: FixtureListener
Is called before the fixture navigation is started.

Specified by:
startFixturring in interface FixtureListener

endFixturring

public void endFixturring()
Description copied from interface: FixtureListener
Is called after the fixture navigation ends.

Specified by:
endFixturring in interface FixtureListener

getAllReporters

public ArrayList getAllReporters()