Hi,
I’ve been trying to Google for an answer to this, but the suggestions I’ve found have been either contradictory or seemingly outdated.
I’m building a Rails frontend for a legacy Oracle database, and I want to do proper tests with RSpec/Cucumber. What I can’t seem to figure out is how to run tests without destroying and rebuilding the database.
I’m well aware that that’s the ‘best practice’ way of doing it… but I’m dealing with a massive, >6GB beast with hundreds of tables, byzantine constraints, and a rat’s nest of spaghetti code in the form of triggers and stored procs.
Seriously, I have nightmares about this database as well.
But, I’ve been slogging away at it, and created a web app that’s impressed the bosses, and the vendor for that matter. But I also have nightmares about the fact that I don’t have a test suite. This horrifies me.
What I’d like to do is test against the dev db, since if it gets horribly b0rked, I can restore from the previous night’s ComVault backup.
I saw the suggestion to edit the rake task in the old rspec_on_rails plugin so that
spec_prereq = :noop
I was curious if there was a good way to do this with the current rspec-rails gem…
I’m on Ruby 1.9.2 and Rails 3.0.4
Thanks,
Jason Lewis
Email jasonlewis.x@gmail.com
Mobile 414.310.2665