mirror of
https://github.com/libp2p/go-libp2p.git
synced 2026-04-23 00:27:05 +08:00
sync: update CI config files (#2073)
* bump go.mod to Go 1.19 and run go fix * stop using the deprecated io/ioutil package * bump go.mod to Go 1.19 and run go fix * bump go.mod to Go 1.19 and run go fix * bump go.mod to Go 1.19 and run go fix * stop using the deprecated io/ioutil package * bump go.mod to Go 1.19 and run go fix * stop using the deprecated io/ioutil package * update .github/workflows/go-test.yml * update .github/workflows/go-check.yml * update .github/workflows/release-check.yml * various fixes * stop using deprecated math/rand.Read --------- Co-authored-by: web3-bot <web3-bot@users.noreply.github.com> Co-authored-by: Marten Seemann <martenseemann@gmail.com>
This commit is contained in:
@@ -3,9 +3,9 @@ package relay_test
|
||||
import (
|
||||
"bytes"
|
||||
"context"
|
||||
"crypto/rand"
|
||||
"fmt"
|
||||
"io"
|
||||
"math/rand"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
@@ -325,8 +325,7 @@ func TestRelayLimitData(t *testing.T) {
|
||||
|
||||
buf := make([]byte, 1024)
|
||||
for i := 0; i < 3; i++ {
|
||||
_, err = rand.Read(buf)
|
||||
if err != nil {
|
||||
if _, err := rand.Read(buf); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
@@ -345,8 +344,7 @@ func TestRelayLimitData(t *testing.T) {
|
||||
}
|
||||
|
||||
buf = make([]byte, 4096)
|
||||
_, err = rand.Read(buf)
|
||||
if err != nil {
|
||||
if _, err := rand.Read(buf); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user