mirror of
https://gitlab.com/pulsechaincom/prysm-pulse.git
synced 2025-01-06 09:42:19 +00:00
b8fe4228af
* add mutex on top of p2p feeds map * lock read too * add concurrent write test and enable race detector * restrict race detection to concurrent feed map write test * gazelle fix * increase ram and I/O in bazel's local_resources * reverted local_resources changes * address review comments * do not disable sandboxing on travis * address review comments
15 lines
215 B
Go
15 lines
215 B
Go
package p2p
|
|
|
|
import "testing"
|
|
|
|
func TestFeed_ConcurrentWrite(t *testing.T) {
|
|
s, err := NewServer()
|
|
if err != nil {
|
|
t.Fatalf("could not create server %v", err)
|
|
}
|
|
|
|
for i := 0; i < 5; i++ {
|
|
go s.Feed("a")
|
|
}
|
|
}
|