Sha256: 5f9b6958854eb8809418c7a36dfd4a34d5f6adc3f2f30897fcef524c8a3c625b
Contents?: true
Size: 991 Bytes
Versions: 37
Compression:
Stored size: 991 Bytes
Contents
require 'rails_helper' describe "CamaleonCms::HtmlMailer" do describe 'empty content' do get_current_test_site() let(:mail) { CamaleonCms::HtmlMailer.sender('test@gmail.com', "test") } it 'renders the subject' do expect(mail.subject).to eql('test') end it 'renders the receiver email' do expect(mail.to).to eql(['test@gmail.com']) end it 'renders the sender email' do expect(mail.from).to eql(['owenperedo@gmail.com']) end it 'html layout text' do expect(mail.body.encoded).to match('Visit Site') end end describe 'custom content' do get_current_test_site() let(:mail) { CamaleonCms::HtmlMailer.sender('test@gmail.com', "test", content: 'custom content', cc_to: ['a@gmail.com', 'b@gmail.com']) } it 'renders the sender email' do expect(mail.cc).to eql(['a@gmail.com', 'b@gmail.com']) end it 'custom content' do expect(mail.body.encoded).to match('custom content') end end end
Version data entries
37 entries across 37 versions & 1 rubygems