diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2006-09-03 22:43:24 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2006-09-03 22:43:24 +0000 |
commit | 268c1dee8f1297991f0836261e5fdde4c372945f (patch) | |
tree | ba525e8f0d7ba8eee7e14244ff8d007fccfc59fe | |
parent | 4bd444c1fe960e757819fb67dada0a5a0bf344e4 (diff) | |
download | rails-268c1dee8f1297991f0836261e5fdde4c372945f.tar.gz rails-268c1dee8f1297991f0836261e5fdde4c372945f.tar.bz2 rails-268c1dee8f1297991f0836261e5fdde4c372945f.zip |
Require action mailer more gracefully
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4944 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
-rw-r--r-- | actionpack/test/controller/assert_select_test.rb | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/actionpack/test/controller/assert_select_test.rb b/actionpack/test/controller/assert_select_test.rb index cd1ba129a5..0d48b99425 100644 --- a/actionpack/test/controller/assert_select_test.rb +++ b/actionpack/test/controller/assert_select_test.rb @@ -5,9 +5,18 @@ require File.dirname(__FILE__) + '/../abstract_unit' require File.dirname(__FILE__) + '/fake_controllers' -require "action_mailer" +unless defined?(ActionMailer) + begin + $:.unshift(File.dirname(__FILE__) + "/../../../actionmailer/lib") + require 'active_mailer' + rescue LoadError + require 'rubygems' + require_gem 'actionmailer' + end +end + class AssertSelectTest < Test::Unit::TestCase class AssertSelectController < ActionController::Base def response_with=(content) |