mvcc: fix race in TestKVTxnBlockWriteOperations

This commit is contained in:
Gaurav Singh 2020-04-25 22:48:04 -04:00
parent 59f5fb25a5
commit e5ddc91228

View File

@ -410,10 +410,11 @@ func TestKVTxnBlockWriteOperations(t *testing.T) {
func() { s.DeleteRange([]byte("foo"), nil) },
}
for i, tt := range tests {
tf := tt
txn := s.Write(traceutil.TODO())
done := make(chan struct{}, 1)
go func() {
tt()
tf()
done <- struct{}{}
}()
select {