diff options
author | Yehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com> | 2009-10-20 16:33:54 -0700 |
---|---|---|
committer | Yehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com> | 2009-10-20 16:34:44 -0700 |
commit | 4f6d6f7031a88b647814fc0154e6b69b636dc912 (patch) | |
tree | 9752430c715e0b5d32713882c267d41554710246 /actionmailer/test | |
parent | a5c82a9dfb6d63bf90a3378da0b71d6ea592d7e3 (diff) | |
download | rails-4f6d6f7031a88b647814fc0154e6b69b636dc912.tar.gz rails-4f6d6f7031a88b647814fc0154e6b69b636dc912.tar.bz2 rails-4f6d6f7031a88b647814fc0154e6b69b636dc912.zip |
Have all the tests running off a single Gemfile
Diffstat (limited to 'actionmailer/test')
-rw-r--r-- | actionmailer/test/abstract_unit.rb | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/actionmailer/test/abstract_unit.rb b/actionmailer/test/abstract_unit.rb index 7843623996..fcbaa9e186 100644 --- a/actionmailer/test/abstract_unit.rb +++ b/actionmailer/test/abstract_unit.rb @@ -1,15 +1,15 @@ -bundled = "#{File.dirname(__FILE__)}/../vendor/gems/environment" -if File.exist?("#{bundled}.rb") - require bundled -else - $:.unshift "#{File.dirname(__FILE__)}/../../activesupport/lib" - $:.unshift "#{File.dirname(__FILE__)}/../../actionpack/lib" +root = File.expand_path('../../..', __FILE__) +begin + require "#{root}/vendor/gems/environment" +rescue LoadError + $:.unshift("#{root}/activesupport/lib") + $:.unshift("#{root}/actionpack/lib") + $:.unshift("#{root}/actionmailer/lib") end require 'rubygems' require 'test/unit' -$:.unshift "#{File.dirname(__FILE__)}/../lib" require 'action_mailer' require 'action_mailer/test_case' |