go-libp2p-core/test/peer.go

19 lines
422 B
Go
Raw Normal View History

package test
import (
"testing"
2022-08-18 23:54:48 +08:00
"github.com/libp2p/go-libp2p/core/peer"
"github.com/libp2p/go-libp2p/core/test"
)
2022-08-18 23:54:48 +08:00
// Deprecated: use github.com/libp2p/go-libp2p/core/test.RandPeerID instead
func RandPeerID() (peer.ID, error) {
2022-08-18 23:54:48 +08:00
return test.RandPeerID()
}
2022-08-18 23:54:48 +08:00
// Deprecated: use github.com/libp2p/go-libp2p/core/test.RandPeerIDFatal instead
func RandPeerIDFatal(t testing.TB) peer.ID {
2022-08-18 23:54:48 +08:00
return test.RandPeerIDFatal(t)
}