Browse Source

integration: extend timeout to wait

Yicheng Qin 11 năm trước cách đây
mục cha
commit
b44d7f84c4
1 tập tin đã thay đổi với 4 bổ sung1 xóa
  1. 4 1
      integration/v2_http_kv_test.go

+ 4 - 1
integration/v2_http_kv_test.go

@@ -883,7 +883,10 @@ func TestV2WatchKeyInDir(t *testing.T) {
 
 	select {
 	case <-c:
-	case <-time.After(time.Millisecond * 1500):
+	// 1s ttl + 0.5s sync delay + 1.5s disk and network delay
+	// We set that long disk and network delay because travis may be slow
+	// when do system calls.
+	case <-time.After(3 * time.Second):
 		t.Fatal("timed out waiting for watch result")
 	}