fix: lint
This commit is contained in:
parent
cef565f08b
commit
41dcd56334
@ -73,8 +73,10 @@ func TestPadChunkRandEqFFI(t *testing.T) {
|
||||
|
||||
for i := 0; i < 200; i++ {
|
||||
var input [127]byte
|
||||
rand.Read(input[:])
|
||||
|
||||
_, err := rand.Read(input[:])
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
var buf [128]byte
|
||||
|
||||
fr32.Pad(input[:], buf[:])
|
||||
@ -110,8 +112,10 @@ func TestRoundtrip(t *testing.T) {
|
||||
func TestRoundtripChunkRand(t *testing.T) {
|
||||
for i := 0; i < 200; i++ {
|
||||
var input [127]byte
|
||||
rand.Read(input[:])
|
||||
|
||||
_, err := rand.Read(input[:])
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
var buf [128]byte
|
||||
copy(buf[:], input[:])
|
||||
|
||||
@ -128,8 +132,10 @@ func TestRoundtrip16MRand(t *testing.T) {
|
||||
up := abi.PaddedPieceSize(16 << 20).Unpadded()
|
||||
|
||||
input := make([]byte, up)
|
||||
rand.Read(input[:])
|
||||
|
||||
_, err := rand.Read(input[:])
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
buf := make([]byte, 16<<20)
|
||||
|
||||
fr32.Pad(input, buf)
|
||||
|
Loading…
Reference in New Issue
Block a user