aboutsummaryrefslogtreecommitdiffstats
path: root/spec/spec_helper.rb
diff options
context:
space:
mode:
authorfrancis <francis>2007-11-13 10:22:14 +0000
committerfrancis <francis>2007-11-13 10:22:14 +0000
commit2c90695ca2d6b5be61d4b23e8e9ad3a389fcd5f5 (patch)
treec897db6b98f2e3ad111ce257135b1e05150f1e1d /spec/spec_helper.rb
parentdc965b43e5784d6dde2f06186cb14c4640da65a4 (diff)
Test incoming request response emails.
Diffstat (limited to 'spec/spec_helper.rb')
-rw-r--r--spec/spec_helper.rb10
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
+
+
+