Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Require action mailer more gracefully

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4944 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
commit 268c1dee8f1297991f0836261e5fdde4c372945f 1 parent 4bd444c
@dhh dhh authored
Showing with 10 additions and 1 deletion.
  1. +10 −1 actionpack/test/controller/assert_select_test.rb
View
11 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)
Please sign in to comment.
Something went wrong with that request. Please try again.