diff options
Diffstat (limited to 'spec/spec_helper.rb')
-rw-r--r-- | spec/spec_helper.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 2d01d442e..b1427f71d 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -22,3 +22,13 @@ Spec::Runner.configure do |config| # for all of your examples, even those that don't use them. end +# XXX No idea what namespace/class/module to put this in +def receive_incoming_mail(email_name, email_to) + email_name = File.join(Spec::Runner.configuration.fixture_path, email_name) + content = File.read(email_name) + content.gsub!('EMAIL_TO', email_to) + RequestMailer.receive(content) +end + + + |