mirror of
https://github.com/hibiken/asynq.git
synced 2025-10-25 23:06:12 +08:00
Update heartbeat to extend lease of active workers
This commit is contained in:
@@ -651,7 +651,7 @@ func TestLeaseReset(t *testing.T) {
|
||||
clock := timeutil.NewSimulatedClock(now)
|
||||
|
||||
l := NewLease(now.Add(30 * time.Second))
|
||||
l.clock = clock
|
||||
l.Clock = clock
|
||||
|
||||
// Check initial state
|
||||
if !l.IsValid() {
|
||||
@@ -686,7 +686,7 @@ func TestLeaseNotifyExpiration(t *testing.T) {
|
||||
clock := timeutil.NewSimulatedClock(now)
|
||||
|
||||
l := NewLease(now.Add(30 * time.Second))
|
||||
l.clock = clock
|
||||
l.Clock = clock
|
||||
|
||||
select {
|
||||
case <-l.Done():
|
||||
|
||||
Reference in New Issue
Block a user