mirror of
https://gitlab.com/pulsechaincom/prysm-pulse.git
synced 2024-12-25 12:57:18 +00:00
ce28feea45
* add validation * add block db check in validation * merge * in memory caching of seen blocks * basic block processing * Update BUILD.bazel * use new receiveBlockNoPubsub * fix build * add TODO issue numbers * add TODO issue numbers * lint
17 lines
243 B
Go
17 lines
243 B
Go
package testutil
|
|
|
|
import (
|
|
"crypto/rand"
|
|
"testing"
|
|
)
|
|
|
|
// Random32Bytes generates a random 32 byte slice.
|
|
func Random32Bytes(t *testing.T) []byte {
|
|
b := make([]byte, 32)
|
|
_, err := rand.Read(b)
|
|
if err != nil {
|
|
t.Fatal(err)
|
|
}
|
|
return b
|
|
}
|