Fix flaky reporting_event_listener_spec (#6923)
This commit is contained in:
@@ -63,8 +63,9 @@ describe ReportingEventListener do
|
|||||||
|
|
||||||
# this ensures last_non_human_activity method accurately accounts for handoff events
|
# this ensures last_non_human_activity method accurately accounts for handoff events
|
||||||
context 'when last handoff event exists' do
|
context 'when last handoff event exists' do
|
||||||
let(:conversation_updated_at) { 20.seconds.from_now }
|
let(:now) { Time.zone.now }
|
||||||
let(:human_message_created_at) { 62.seconds.from_now }
|
let(:conversation_updated_at) { now + 20.seconds }
|
||||||
|
let(:human_message_created_at) { now + 62.seconds }
|
||||||
let(:new_conversation) { create(:conversation, account: account, inbox: inbox, assignee: user, updated_at: conversation_updated_at) }
|
let(:new_conversation) { create(:conversation, account: account, inbox: inbox, assignee: user, updated_at: conversation_updated_at) }
|
||||||
let(:new_message) do
|
let(:new_message) do
|
||||||
create(:message, message_type: 'outgoing', created_at: human_message_created_at, account: account, inbox: inbox,
|
create(:message, message_type: 'outgoing', created_at: human_message_created_at, account: account, inbox: inbox,
|
||||||
|
|||||||
Reference in New Issue
Block a user