diff options
Diffstat (limited to 'actionmailbox/test/unit/inbound_email_test.rb')
-rw-r--r-- | actionmailbox/test/unit/inbound_email_test.rb | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/actionmailbox/test/unit/inbound_email_test.rb b/actionmailbox/test/unit/inbound_email_test.rb new file mode 100644 index 0000000000..993423406f --- /dev/null +++ b/actionmailbox/test/unit/inbound_email_test.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +require_relative "../test_helper" + +module ActionMailbox + class InboundEmailTest < ActiveSupport::TestCase + test "mail provides the parsed source" do + assert_equal "Discussion: Let's debate these attachments", create_inbound_email_from_fixture("welcome.eml").mail.subject + end + + test "source returns the contents of the raw email" do + assert_equal file_fixture("welcome.eml").read, create_inbound_email_from_fixture("welcome.eml").source + end + end +end |