mirror of
https://github.com/ipfs/kubo.git
synced 2025-09-10 05:52:20 +08:00
Swap all 'crypto/rand' rng in tests with 'math/rand'
This commit is contained in:
@ -4,7 +4,6 @@ package ipns
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"crypto/rand"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
mrand "math/rand"
|
||||
@ -19,6 +18,7 @@ import (
|
||||
core "github.com/ipfs/go-ipfs/core"
|
||||
coremock "github.com/ipfs/go-ipfs/core/mock"
|
||||
nsfs "github.com/ipfs/go-ipfs/ipnsfs"
|
||||
u "github.com/ipfs/go-ipfs/util"
|
||||
ci "github.com/ipfs/go-ipfs/util/testutil/ci"
|
||||
)
|
||||
|
||||
@ -30,7 +30,7 @@ func maybeSkipFuseTests(t *testing.T) {
|
||||
|
||||
func randBytes(size int) []byte {
|
||||
b := make([]byte, size)
|
||||
rand.Read(b)
|
||||
u.NewTimeSeededRand().Read(b)
|
||||
return b
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user