[rspec-users] Story teardowns?
aslak hellesoy
aslak.hellesoy at gmail.com
Fri Jan 11 05:10:46 EST 2008
On Jan 11, 2008 10:53 AM, Andreas Axelsson
<Andreas.Axelsson at combination.se> wrote:
>
>
>
>
> Does the plain text story framework support teardowns? There doesn't seem to
> be anywhere to put an "after" method. My stories test an application which
> parses and modifies a directory tree, which is currently generated in a
> Given-clause, and I want it to be deleted after each story. (I don't mind if
> the stories take a few seconds to run, the specs are still fast)
>
There is no such feature (yet). For now I'd stick this in a Given that
you use at the beginning of each scenario, for example:
Given "the stash is in a clean state" do
# yank any old residual gunk here
end
Aslak
>
>
> Cheers ,
>
> Andreas Axelsson
>
> Combination AB
>
>
> _______________________________________________
> rspec-users mailing list
> rspec-users at rubyforge.org
> http://rubyforge.org/mailman/listinfo/rspec-users
>
More information about the rspec-users
mailing list