fs.addStepListener(new StepListener() {
public void stateChanged(StepEvent event) {
events.add(event);
}
});
fs.run(script);
assertEquals("Wrong number of events", 2, events.size());
assertEquals("Wrong step source, event 0",
script, ((StepEvent)events.get(0)).getStep());
assertEquals("Wrong step id, event 0",
StepEvent.STEP_START,