Hello and happy new year, David's answer and some digging in RDoc of RSpec has lead to the following code sceleton:
class Listener def run_started(number_of_scenarios) end def run_ended end def story_started(title, description) end def story_ended(title, description) end def scenario_started(story_title, scenario_title) end def scenario_succeeded(story_title, scenario_title) end def scenario_failed(story_title, scenario_title, exception) end def scenario_pending(story_title, scenario_title, message) end def step_succeeded(kind_of_step, step_line, *args) end def step_failed(kind_of_step, step_line, *args) end def step_pending(kind_of_step, step_line, *args) end def collected_steps(*args) end end Spec::Story::Runner.register_listener(Listener.new) The above instance methods of Listener has to be implemented. The seem to me self-explaining. Only the last one, Listener# collected_steps, needs further investigation. But I have not needed it yet. Hope this helps, Armin _______________________________________________ rspec-users mailing list [email protected] http://rubyforge.org/mailman/listinfo/rspec-users
