Ed Howland
2007-Jan-12 00:32 UTC
[rspec-users] After upgrade to 0.7.5, specs are now using the development, not the test DB
Hi, After I upgraded RSpec from 0.7.4 to 0.7.5, first the gem, then the Rails plugin, I noticed that when I ran my spec/models, the fixtures were overwriting the data in the development environment DB, not the test one. The test environment was being used prior to the upgrade. I am using SQLite3 and an in-memory db for the test environment. Any help would be appreciated. Thanks Ed -- Ed Howland http://greenprogrammer.blogspot.com
David Chelimsky
2007-Jan-12 03:57 UTC
[rspec-users] After upgrade to 0.7.5, specs are now using the development, not the test DB
Add this to the top of spec_helper.rb: ENV["RAILS_ENV"] = "test" This will not be a problem in the next release. David On 1/11/07, Ed Howland <ed.howland at gmail.com> wrote:> Hi, > > After I upgraded RSpec from 0.7.4 to 0.7.5, first the gem, then the > Rails plugin, I noticed that when I ran my spec/models, the fixtures > were overwriting the data in the development environment DB, not the > test one. The test environment was being used prior to the upgrade. > > I am using SQLite3 and an in-memory db for the test environment. > > Any help would be appreciated. > > Thanks > Ed > -- > Ed Howland > http://greenprogrammer.blogspot.com > _______________________________________________ > rspec-users mailing list > rspec-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users >
Ed Howland
2007-Jan-12 14:23 UTC
[rspec-users] After upgrade to 0.7.5, specs are now using the development, not the test DB
On 1/11/07, David Chelimsky <dchelimsky at gmail.com> wrote:> Add this to the top of spec_helper.rb: > > ENV["RAILS_ENV"] = "test" > > This will not be a problem in the next release. > > DavidThanks, that did the trick. Ed