lib/model: Debug and test fixes (#5613)

This commit is contained in:
Simon Frei
2019-03-22 14:43:47 +01:00
committed by Jakob Borg
parent 73fa7a6e5b
commit e7ae851900
2 changed files with 2 additions and 15 deletions

View File

@@ -370,14 +370,12 @@ func pullInvalidIgnored(t *testing.T, ft config.FolderType) {
fc.sendIndexUpdate()
timeout := time.NewTimer(5 * time.Second)
select {
case ev := <-sub.C():
t.Fatalf("Errors while pulling: %v", ev)
case <-timeout.C:
case <-time.After(5 * time.Second):
t.Fatalf("timed out before index was received")
case <-done:
return
}
fc.mut.Lock()
@@ -421,12 +419,10 @@ func pullInvalidIgnored(t *testing.T, ft config.FolderType) {
panic(err)
}
timeout = time.NewTimer(5 * time.Second)
select {
case <-timeout.C:
case <-time.After(5 * time.Second):
t.Fatalf("timed out before index was received")
case <-done:
return
}
}