[rspec-users] rake spec seems to not clean the database after failing specs

Rick DeNatale rick.denatale at gmail.com
Mon Dec 28 19:22:49 EST 2009

On Mon, Dec 28, 2009 at 6:56 PM, Doug <dgoldie15 at gmail.com> wrote:
> running all specs with 'rake spec'
> working on a spec that gets run last.
> when run individually, it is green.
> but in 'rake spec' it fails because the database is dirty
> I'm guessing this is caused by early specs that fail as well
> ????
> is this normal?
> if that's the problem, what's the best way to force the database to be
> cleaned after each scenario?

Be careful what you wish for.

I normally want to set the database to a known state BEFORE running
specs rather than cleaning up afterwards.

Why?  Because it's easier to debug failures if you preserve the evidence.
Rick DeNatale

Blog: http://talklikeaduck.denhaven2.com/
Twitter: http://twitter.com/RickDeNatale
WWR: http://www.workingwithrails.com/person/9021-rick-denatale
LinkedIn: http://www.linkedin.com/in/rickdenatale

More information about the rspec-users mailing list