diff --git a/test/unit/email_process_test.rb b/test/unit/email_process_test.rb index e8e6190f7..706ca3d25 100644 --- a/test/unit/email_process_test.rb +++ b/test/unit/email_process_test.rb @@ -2047,7 +2047,7 @@ Some Text', updated_by_id: 1, created_by_id: 1, ) - + sleep 1 email_raw_string = IO.read('test/fixtures/mail33-undelivered-mail-returned-to-sender.box') ticket_p, article_p, user_p = Channel::EmailParser.new.process( {}, email_raw_string) assert_equal(ticket.id, ticket_p.id) @@ -2134,35 +2134,45 @@ no reference " setting_orig = Setting.get('postmaster_follow_up_search_in') Setting.set('postmaster_follow_up_search_in', ['body', 'attachment', 'references']) + sleep 1 ticket_p, article_p, user_p = Channel::EmailParser.new.process( {}, email_raw_string_subject) assert_equal(ticket.id, ticket_p.id) + sleep 1 ticket_p, article_p, user_p = Channel::EmailParser.new.process( {}, email_raw_string_body) assert_equal(ticket.id, ticket_p.id) + sleep 1 ticket_p, article_p, user_p = Channel::EmailParser.new.process( {}, email_raw_string_attachment) assert_equal(ticket.id, ticket_p.id) + sleep 1 ticket_p, article_p, user_p = Channel::EmailParser.new.process( {}, email_raw_string_references1) assert_equal(ticket.id, ticket_p.id) + sleep 1 ticket_p, article_p, user_p = Channel::EmailParser.new.process( {}, email_raw_string_references2) assert_equal(ticket.id, ticket_p.id) Setting.set('postmaster_follow_up_search_in', setting_orig) + sleep 1 ticket_p, article_p, user_p = Channel::EmailParser.new.process( {}, email_raw_string_subject) assert_equal(ticket.id, ticket_p.id) + sleep 1 ticket_p, article_p, user_p = Channel::EmailParser.new.process( {}, email_raw_string_body) assert_not_equal(ticket.id, ticket_p.id) + sleep 1 ticket_p, article_p, user_p = Channel::EmailParser.new.process( {}, email_raw_string_attachment) assert_not_equal(ticket.id, ticket_p.id) + sleep 1 ticket_p, article_p, user_p = Channel::EmailParser.new.process( {}, email_raw_string_references1) assert_not_equal(ticket.id, ticket_p.id) + sleep 1 ticket_p, article_p, user_p = Channel::EmailParser.new.process( {}, email_raw_string_references2) assert_not_equal(ticket.id, ticket_p.id) end