Commit b113612a8fadefe53bec67972f6d7ac00a802c3d
- Date: Sun Mar 30 13:38:26 +0000 2008
- Committer: David Chelimsky (dchelimsky@gmail.com)
- Author: David Chelimsky (dchelimsky@gmail.com)
- Commit SHA1: b113612a8fadefe53bec67972f6d7ac00a802c3d
- Tree SHA1: fa032f4968c80ffc1ed170cbf044961cad7ea44e
Added vendor_rails? method to boot.rb in rails app to support older and newer versions of rails simultaneously. Closes #351.
Commit diff
| |   |
| 10 | 10 | RAILS_ROOT = root_path |
| 11 | 11 | end |
| 12 | 12 | |
| 13 | module Rails |
| 14 | class << self |
| 15 | def vendor_rails? |
| 16 | true |
| 17 | end |
| 18 | end |
| 19 | end |
| 20 | |
| 13 | 21 | ENV['RSPEC_RAILS_VERSION'] ||= "edge" |
| 14 | 22 | puts "running against rails #{ENV['RSPEC_RAILS_VERSION']}" |
| 15 | 23 | |
| toggle raw diff |
--- a/example_rails_app/config/boot.rb
+++ b/example_rails_app/config/boot.rb
@@ -10,6 +10,14 @@ unless defined?(RAILS_ROOT)
RAILS_ROOT = root_path
end
+module Rails
+ class << self
+ def vendor_rails?
+ true
+ end
+ end
+end
+
ENV['RSPEC_RAILS_VERSION'] ||= "edge"
puts "running against rails #{ENV['RSPEC_RAILS_VERSION']}"
|