2020-01-09 07:36:40 +00:00
|
|
|
require 'rails_helper'
|
|
|
|
|
|
|
|
describe ::MessageTemplates::Template::EmailCollect do
|
|
|
|
context 'when this hook is called' do
|
|
|
|
let(:conversation) { create(:conversation) }
|
|
|
|
|
|
|
|
it 'creates the email collect messages' do
|
|
|
|
described_class.new(conversation: conversation).perform
|
2020-06-09 18:24:35 +00:00
|
|
|
expect(conversation.messages.count).to eq(2)
|
2020-01-09 07:36:40 +00:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|