mirror of
https://github.com/restic/restic.git
synced 2025-10-27 08:01:14 +00:00
Update dependencies
This commit is contained in:
5
vendor/cloud.google.com/go/spanner/session_test.go
generated
vendored
5
vendor/cloud.google.com/go/spanner/session_test.go
generated
vendored
@@ -806,6 +806,7 @@ func TestStressSessionPool(t *testing.T) {
|
||||
}
|
||||
idleSessions[s.getID()] = true
|
||||
}
|
||||
sp.mu.Lock()
|
||||
if int(sp.numOpened) != len(idleSessions) {
|
||||
t.Errorf("%v: number of opened sessions (%v) != number of idle sessions (%v)", ti, sp.numOpened, len(idleSessions))
|
||||
}
|
||||
@@ -819,6 +820,8 @@ func TestStressSessionPool(t *testing.T) {
|
||||
}
|
||||
hcSessions[s.getID()] = true
|
||||
}
|
||||
sp.mu.Unlock()
|
||||
|
||||
// Verify that idleSessions == hcSessions == mockSessions.
|
||||
if !reflect.DeepEqual(idleSessions, hcSessions) {
|
||||
t.Errorf("%v: sessions in idle list (%v) != sessions in healthcheck queue (%v)", ti, idleSessions, hcSessions)
|
||||
@@ -853,9 +856,11 @@ func TestMaintainer(t *testing.T) {
|
||||
defer cancel()
|
||||
|
||||
<-time.After(sampleInterval * 1)
|
||||
sp.mu.Lock()
|
||||
if sp.numOpened != 5 {
|
||||
t.Errorf("Replenish. Expect %d open, got %d", sp.MinOpened, sp.numOpened)
|
||||
}
|
||||
sp.mu.Unlock()
|
||||
|
||||
// To save test time, we are not creating many sessions, because the time to create sessions will have impact on the decision on sessionsToKeep. We also parallelize the take and recycle process.
|
||||
shs := make([]*sessionHandle, 10)
|
||||
|
||||
Reference in New Issue
Block a user