With Rails 3, I get these two deprecation warnings in my app when running specs.
DEPRECATION WARNING: Use toplevel init.rb; rails/init.rb is deprecated: /vagrant/vendor/plugins/more/rails/init.rb. (called from /vagrant/config/environment.rb:5)
DEPRECATION WARNING: RAILS_ENV is deprecated. Please use ::Rails.env. (called from /vagrant/vendor/plugins/more/rails/init.rb:1)
To fix it, I moved init.rb one directory up, and changed the contents to read
require File.join(File.dirname(FILE), 'lib', 'less', 'controller_extension') if ::Rails.env == 'development'
With Rails 3, I get these two deprecation warnings in my app when running specs.
DEPRECATION WARNING: Use toplevel init.rb; rails/init.rb is deprecated: /vagrant/vendor/plugins/more/rails/init.rb. (called from /vagrant/config/environment.rb:5) DEPRECATION WARNING: RAILS_ENV is deprecated. Please use ::Rails.env. (called from /vagrant/vendor/plugins/more/rails/init.rb:1)
To fix it, I moved init.rb one directory up, and changed the contents to read
require File.join(File.dirname(FILE), 'lib', 'less', 'controller_extension') if ::Rails.env == 'development'