[rspec-devel] BehaviourRunner and ExampleSuite
aslak.hellesoy at gmail.com
Sat Sep 22 11:09:30 EDT 2007
I've noticed that BehaviourRunner#prepare is invoked via two different chains:
bin/spec -> CommandLine#run -> BehaviourRunner#run -> BehaviourRunner#prepare
test/unit/testsuite.rb -> ExampleSute#run -> BehaviourRunner#prepare
In one single run, #prepare gets called twice, and returns the second
time because of the @already_prepared check.
This is all quite confusing to me, and the number of delegators in
ExampleSuite makes it even more confusing. Now that we're using
Test::Unit's runner it occurs to me that we should get rid of our own
"runner" stuff, but there still seems to be a lot of redundancy. The
code is plain hard to understand.
You who've been involved in the Test::Unit refactoring - are you
planning to simplify things more and get rid of our own runner?
More information about the rspec-devel