diff options
Diffstat (limited to 'railties/test/abstract_unit.rb')
-rw-r--r-- | railties/test/abstract_unit.rb | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/railties/test/abstract_unit.rb b/railties/test/abstract_unit.rb index 7b773531c6..e1ce32da65 100644 --- a/railties/test/abstract_unit.rb +++ b/railties/test/abstract_unit.rb @@ -4,18 +4,9 @@ $:.unshift File.dirname(__FILE__) + "/../lib" $:.unshift File.dirname(__FILE__) + "/../builtin/rails_info" require 'test/unit' +require 'stringio' require 'active_support' -if defined?(RAILS_ROOT) - RAILS_ROOT.replace File.dirname(__FILE__) -else - RAILS_ROOT = File.dirname(__FILE__) -end - -class Test::Unit::TestCase - # Add stuff here if you need it -end - # Wrap tests that use Mocha and skip if unavailable. def uses_mocha(test_name) require 'rubygems' @@ -25,3 +16,9 @@ def uses_mocha(test_name) rescue LoadError $stderr.puts "Skipping #{test_name} tests. `gem install mocha` and try again." end + +if defined?(RAILS_ROOT) + RAILS_ROOT.replace File.dirname(__FILE__) +else + RAILS_ROOT = File.dirname(__FILE__) +end |