Forg/test/helpers/mailer_helper_test.rb

24 lines
463 B
Ruby
Raw Normal View History

2024-04-14 19:01:32 +00:00
require "test_helper"
class MailerHelperTest < ActionView::TestCase
test "htmlify_email adds correct tags" do
input = <<~TEST.chomp
One line here.
Another one here.
The same paragraph.
And another.
TEST
expected_output = <<~TEST.chomp
<p>One line here.</p>
<p>Another one here.
The same paragraph.</p>
<p>And another.</p>
TEST
assert_equal expected_output, htmlify_email(input)
end
end