[rspec-users] at_exit in spec file?

Ashley Moran ashley.moran at patchspace.co.uk
Wed Oct 28 16:52:48 EDT 2009


On 28 Oct 2009, at 20:42, Student wrote:

> So now I'm
> back to the "undefined method `after' for main:Object (NoMethodError)"
> problem.

I think it was just a typo on David's part.  Does the following work?

   Spec::Runner.configure do |config|
     config.after(:suite) do
       # shut stuff down here
     end
   end

And I had no idea you could do before/after :suite...

Ashley

-- 
http://www.patchspace.co.uk/
http://www.linkedin.com/in/ashleymoran
http://aviewfromafar.net/









More information about the rspec-users mailing list