mirror of
https://github.com/octoleo/restic.git
synced 2024-12-23 03:18:55 +00:00
Increase waiting time for network services
This commit is contained in:
parent
88de3cfecc
commit
ec5e984ed9
@ -32,9 +32,10 @@ func runRESTServer(ctx context.Context, t testing.TB, dir string) func() {
|
||||
// wait until the TCP port is reachable
|
||||
var success bool
|
||||
for i := 0; i < 10; i++ {
|
||||
time.Sleep(200 * time.Millisecond)
|
||||
|
||||
c, err := net.Dial("tcp", "localhost:8000")
|
||||
if err != nil {
|
||||
time.Sleep(200 * time.Millisecond)
|
||||
continue
|
||||
}
|
||||
|
||||
|
@ -50,9 +50,10 @@ func runMinio(ctx context.Context, t testing.TB, dir, key, secret string) func()
|
||||
// wait until the TCP port is reachable
|
||||
var success bool
|
||||
for i := 0; i < 10; i++ {
|
||||
time.Sleep(200 * time.Millisecond)
|
||||
|
||||
c, err := net.Dial("tcp", "localhost:9000")
|
||||
if err != nil {
|
||||
time.Sleep(200 * time.Millisecond)
|
||||
continue
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user