diff --git a/lib/sessions/backend/base.rb b/lib/sessions/backend/base.rb index fa0ef90bd..bd85471e4 100644 --- a/lib/sessions/backend/base.rb +++ b/lib/sessions/backend/base.rb @@ -30,7 +30,7 @@ class Sessions::Backend::Base return true if @asset_lookup[class_name][record_id].blank? return true if @asset_lookup[class_name][record_id][:updated_at] < updated_at return true if @asset_lookup[class_name][record_id][:pushed_at].blank? - return true if @asset_lookup[class_name][record_id][:pushed_at] < Time.zone.now - 1.hour + return true if @asset_lookup[class_name][record_id][:pushed_at] < Time.zone.now - 2.hours false end diff --git a/test/unit/session_basic_ticket_test.rb b/test/unit/session_basic_ticket_test.rb index 8cd707a6d..2defadf8e 100644 --- a/test/unit/session_basic_ticket_test.rb +++ b/test/unit/session_basic_ticket_test.rb @@ -53,7 +53,7 @@ class SessionBasicTicketTest < ActiveSupport::TestCase assert_not(client1.asset_needed_by_updated_at?(ticket.class.to_s, ticket.id, ticket.updated_at)) assert_not(client2.asset_needed_by_updated_at?(ticket.class.to_s, ticket.id, ticket.updated_at)) - travel 60.minutes + travel 120.minutes assert(client1.asset_needed_by_updated_at?(ticket.class.to_s, ticket.id, ticket.updated_at)) client1.asset_push(ticket, {}) @@ -75,7 +75,7 @@ class SessionBasicTicketTest < ActiveSupport::TestCase assert_not(client1.asset_needed?(ticket)) assert_not(client2.asset_needed?(ticket)) - travel 65.minutes + travel 125.minutes assert(client1.asset_needed?(ticket)) client1.asset_push(ticket, {}) @@ -153,7 +153,7 @@ class SessionBasicTicketTest < ActiveSupport::TestCase assert_not(result1[1][:data][:assets][:Ticket][ticket3.id]) assert_equal(result1[1][:data][:assets][:Ticket][ticket4.id]['title'], ticket4.title) - travel 65.minutes + travel 125.minutes ticket1.touch result1 = client1.push assert(result1, 'check ticket_overview_index - recall 8') diff --git a/test/unit/session_collections_test.rb b/test/unit/session_collections_test.rb index c4fc2caa2..0af97e5d1 100644 --- a/test/unit/session_collections_test.rb +++ b/test/unit/session_collections_test.rb @@ -200,7 +200,7 @@ class SessionCollectionsTest < ActiveSupport::TestCase assert(data[:assets]) assert_not(data[:assets][:Group]) - travel 65.minutes + travel 125.minutes client1 = Sessions::Backend::Collections::Group.new(agent1, assets, false, '123-1', 4) data = client1.push