* We also report the transition coverage of the model.
*/
public static void main(String args[])
{
// create our model and a test generation algorithm
Tester tester = new RandomTester(new SpecialFSMNoLoops());
// build the complete FSM graph for our model, just to ensure
// that we get accurate model coverage metrics.
tester.buildGraph();
// set up our favourite coverage metric
CoverageMetric trCoverage = new TransitionCoverage();
tester.addListener(trCoverage);
// ask to print the generated tests
tester.addListener("verbose");
// generate a small test suite of 20 steps (covers 4/5 transitions)
tester.generate(100);
tester.getModel().printMessage(trCoverage.getName() + " was "
+ trCoverage.toString());
}