Improved unit tests.
This commit is contained in:
parent
fbf644faa1
commit
39caffc603
2 changed files with 9 additions and 4 deletions
|
@ -203,6 +203,11 @@ Some Text',
|
|||
end
|
||||
|
||||
test 'process with postmaster filter' do
|
||||
group = Group.create_if_not_exists(
|
||||
:name => 'Test Group',
|
||||
:created_by_id => 1,
|
||||
:updated_by_id => 1,
|
||||
)
|
||||
PostmasterFilter.destroy_all
|
||||
PostmasterFilter.create(
|
||||
:name => 'not used',
|
||||
|
@ -223,7 +228,7 @@ Some Text',
|
|||
:from => 'me@example.com',
|
||||
},
|
||||
:perform => {
|
||||
'X-Zammad-Ticket-group_id' => 2,
|
||||
'X-Zammad-Ticket-group_id' => group.id,
|
||||
'x-Zammad-Article-Internal' => true,
|
||||
},
|
||||
:channel => 'email',
|
||||
|
@ -256,7 +261,7 @@ Some Text',
|
|||
:success => true,
|
||||
:result => {
|
||||
0 => {
|
||||
:group => 'Twitter',
|
||||
:group => group.name,
|
||||
:ticket_priority => '2 normal',
|
||||
:title => 'some subject',
|
||||
},
|
||||
|
|
|
@ -140,7 +140,7 @@ class TwitterTest < ActiveSupport::TestCase
|
|||
dms.each {|dm|
|
||||
client.destroy_direct_message(dm.id)
|
||||
}
|
||||
sleep 5
|
||||
sleep 10
|
||||
|
||||
hash = '#citheo44' + rand(9999).to_s
|
||||
text = 'How about the details? ' + hash
|
||||
|
@ -154,7 +154,7 @@ class TwitterTest < ActiveSupport::TestCase
|
|||
article = nil
|
||||
(1..4).each {|loop|
|
||||
next if article
|
||||
sleep 15
|
||||
sleep 25
|
||||
|
||||
Channel.fetch
|
||||
|
||||
|
|
Loading…
Reference in a new issue