Permalink
Browse files

Using InstanceMethods in a Concern is deprecated

  • Loading branch information...
1 parent 3b07bb3 commit b757663af7063eb2e1fa09546e415abe977be011 @jeremy jeremy committed Nov 30, 2011
Showing with 6 additions and 10 deletions.
  1. +6 −10 actionmailer/lib/action_mailer/test_case.rb
@@ -15,6 +15,12 @@ module Behavior
include TestHelper
+ included do
+ class_attribute :_mailer_class
+ setup :initialize_test_deliveries
+ setup :set_expected_mail
+ end
+
module ClassMethods
def tests(mailer)
case mailer
@@ -42,8 +48,6 @@ def determine_default_mailer(name)
end
end
- module InstanceMethods
-
protected
def initialize_test_deliveries
@@ -71,16 +75,8 @@ def encode(subject)
def read_fixture(action)
IO.readlines(File.join(Rails.root, 'test', 'fixtures', self.class.mailer_class.name.underscore, action))
end
- end
-
- included do
- class_attribute :_mailer_class
- setup :initialize_test_deliveries
- setup :set_expected_mail
- end
end
include Behavior
-
end
end

0 comments on commit b757663

Please sign in to comment.