Improved timings.
This commit is contained in:
parent
ed89ed2af0
commit
c38b44562b
1 changed files with 12 additions and 14 deletions
|
@ -24,25 +24,24 @@ class SessionBasicTicketTest < ActiveSupport::TestCase
|
|||
assert( agent1.save, "create/update agent1" )
|
||||
|
||||
user = User.lookup( :id => agent1.id )
|
||||
client1 = Sessions::Backend::TicketOverviewIndex.new(user, false, '123-1')
|
||||
client1 = Sessions::Backend::TicketOverviewIndex.new(user, false, '123-1', 3)
|
||||
|
||||
# get as stream
|
||||
result1 = client1.push
|
||||
assert( result1, "check ticket_overview_index" )
|
||||
sleep 1
|
||||
|
||||
# next check should be empty
|
||||
# next check should be empty / no changes
|
||||
result1 = client1.push
|
||||
assert( !result1, "check ticket_overview_index - recall" )
|
||||
|
||||
# next check should be empty
|
||||
sleep 8
|
||||
# next check should be empty / no changes
|
||||
sleep 4
|
||||
result1 = client1.push
|
||||
assert( !result1, "check ticket_overview_index - recall 2" )
|
||||
|
||||
# create ticket
|
||||
ticket = Ticket.create( :title => '12323', :group_id => 1, :priority_id => 1, :state_id => 1, :customer_id => 1 )
|
||||
|
||||
sleep 8
|
||||
sleep 4
|
||||
|
||||
# get as stream
|
||||
result1 = client1.push
|
||||
|
@ -72,25 +71,24 @@ class SessionBasicTicketTest < ActiveSupport::TestCase
|
|||
|
||||
user = User.lookup( :id => agent1.id )
|
||||
|
||||
client1 = Sessions::Backend::TicketOverviewList.new(user, false, '123-1')
|
||||
client1 = Sessions::Backend::TicketOverviewList.new(user, false, '123-1', 3)
|
||||
|
||||
# get as stream
|
||||
result1 = client1.push
|
||||
assert( result1, "check ticket_overview_list" )
|
||||
sleep 1
|
||||
|
||||
# next check should be empty
|
||||
# next check should be empty / no changes
|
||||
result1 = client1.push
|
||||
assert( !result1, "check ticket_overview_list - recall" )
|
||||
|
||||
# next check should be empty
|
||||
sleep 8
|
||||
# next check should be empty / no changes
|
||||
sleep 4
|
||||
result1 = client1.push
|
||||
assert( !result1, "check ticket_overview_list - recall 2" )
|
||||
|
||||
# create ticket
|
||||
ticket = Ticket.create( :title => '12323', :group_id => 1, :priority_id => 1, :state_id => 1, :customer_id => 1 )
|
||||
|
||||
sleep 8
|
||||
sleep 4
|
||||
|
||||
# get as stream
|
||||
result1 = client1.push
|
||||
|
|
Loading…
Reference in a new issue