aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFelix Lange <fjl@twurst.com>2015-07-30 00:12:55 +0800
committerFelix Lange <fjl@twurst.com>2015-08-02 06:49:53 +0800
commit5aec1d94add9211298a672cd8f3377785519c95e (patch)
tree1cab183fdde3a3284b055612bc0d3afd6d1fd550
parentd18d256442e2dc3413ebd9f571e1a5f6be366c09 (diff)
downloaddexon-5aec1d94add9211298a672cd8f3377785519c95e.tar
dexon-5aec1d94add9211298a672cd8f3377785519c95e.tar.gz
dexon-5aec1d94add9211298a672cd8f3377785519c95e.tar.bz2
dexon-5aec1d94add9211298a672cd8f3377785519c95e.tar.lz
dexon-5aec1d94add9211298a672cd8f3377785519c95e.tar.xz
dexon-5aec1d94add9211298a672cd8f3377785519c95e.tar.zst
dexon-5aec1d94add9211298a672cd8f3377785519c95e.zip
accounts: bump timeout and spin less in TestSignRace
This should fix the flakeyness.
-rw-r--r--accounts/accounts_test.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/accounts/accounts_test.go b/accounts/accounts_test.go
index 94c2489fd..29a92f390 100644
--- a/accounts/accounts_test.go
+++ b/accounts/accounts_test.go
@@ -128,7 +128,7 @@ func TestSignRace(t *testing.T) {
if err := am.TimedUnlock(a1.Address, "", 15*time.Millisecond); err != nil {
t.Fatalf("could not unlock the test account", err)
}
- end := time.Now().Add(80 * time.Millisecond)
+ end := time.Now().Add(500 * time.Millisecond)
for time.Now().Before(end) {
if _, err := am.Sign(a1, testSigData); err == ErrLocked {
return
@@ -136,6 +136,7 @@ func TestSignRace(t *testing.T) {
t.Errorf("Sign error: %v", err)
return
}
+ time.Sleep(1 * time.Millisecond)
}
t.Errorf("Account did not lock within the timeout")
}