forked from TrueCloudLab/restic
Increase waiting time for network services
This commit is contained in:
parent
88de3cfecc
commit
ec5e984ed9
2 changed files with 4 additions and 2 deletions
|
@ -32,9 +32,10 @@ func runRESTServer(ctx context.Context, t testing.TB, dir string) func() {
|
||||||
// wait until the TCP port is reachable
|
// wait until the TCP port is reachable
|
||||||
var success bool
|
var success bool
|
||||||
for i := 0; i < 10; i++ {
|
for i := 0; i < 10; i++ {
|
||||||
|
time.Sleep(200 * time.Millisecond)
|
||||||
|
|
||||||
c, err := net.Dial("tcp", "localhost:8000")
|
c, err := net.Dial("tcp", "localhost:8000")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
time.Sleep(200 * time.Millisecond)
|
|
||||||
continue
|
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
|
// wait until the TCP port is reachable
|
||||||
var success bool
|
var success bool
|
||||||
for i := 0; i < 10; i++ {
|
for i := 0; i < 10; i++ {
|
||||||
|
time.Sleep(200 * time.Millisecond)
|
||||||
|
|
||||||
c, err := net.Dial("tcp", "localhost:9000")
|
c, err := net.Dial("tcp", "localhost:9000")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
time.Sleep(200 * time.Millisecond)
|
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue