Skip to content

Commit fa8015f

Browse files
committed
Fix flaky unit test when waiting for free port
Adding more waiting time should make it stabile.
1 parent 10857d3 commit fa8015f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pbm/restore/physical_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ func TestWaitMgoFreePort(t *testing.T) {
203203
t.Fatalf("error while waiting for the free port: %v", err)
204204
}
205205
if duration < portUsed-time.Second ||
206-
duration > portUsed+time.Second {
206+
duration > portUsed+2*time.Second {
207207
t.Fatalf("wrong duration time, want~=%v, got=%v", portUsed, duration)
208208
}
209209
})

0 commit comments

Comments
 (0)