Просмотр исходного кода

Merge pull request #4735 from xiang90/fix_write

clientv3/integration: fix TestTxnWriteFail
Xiang Li 10 лет назад
Родитель
Сommit
6343410e24
1 измененных файлов с 2 добавлено и 1 удалено
  1. 2 1
      clientv3/integration/txn_test.go

+ 2 - 1
clientv3/integration/txn_test.go

@@ -45,8 +45,9 @@ func TestTxnWriteFail(t *testing.T) {
 		donec <- struct{}{}
 	}()
 
+	dialTimeout := 5 * time.Second
 	select {
-	case <-time.After(5 * time.Second):
+	case <-time.After(2*dialTimeout + time.Second):
 		t.Fatalf("timed out waiting for txn to fail")
 	case <-donec:
 		// don't restart cluster until txn errors out