[rspec-users] rake spec loads development environment

Jared M. lists at ruby-forum.com
Mon Mar 21 14:04:44 EDT 2011

This thread has been dead for awhile, but I'm having the same issue.  I 
don't have a bash variable set.  I'm also having this issue with 
Cucumber.  It always runs in development mode.

If I put "p Rails.env" in spec_helper.rb:8 (after spec_helper already 
declares ENV["RAILS_ENV"] ||= "test") and run "rake spec" it outputs 
"development" every time.  If I run "spec spec/*/**" it outputs "test" 
like it should.

My setup:

Rails 2.3.9
Rake 0.8.7
Bundler 1.0.10
Rspec-rails 1.3.3
Rspec 1.3.1

Posted via http://www.ruby-forum.com/.

More information about the rspec-users mailing list