fix
This commit is contained in:
parent
8cc5885339
commit
140c5392e5
4 changed files with 16 additions and 16 deletions
|
@ -12,7 +12,7 @@ import (
|
||||||
|
|
||||||
"github.com/lbryio/herald.go/internal/metrics"
|
"github.com/lbryio/herald.go/internal/metrics"
|
||||||
pb "github.com/lbryio/herald.go/protobuf/go"
|
pb "github.com/lbryio/herald.go/protobuf/go"
|
||||||
server "github.com/lbryio/herald.go/server"
|
"github.com/lbryio/herald.go/server"
|
||||||
"github.com/lbryio/lbry.go/v3/extras/stop"
|
"github.com/lbryio/lbry.go/v3/extras/stop"
|
||||||
dto "github.com/prometheus/client_model/go"
|
dto "github.com/prometheus/client_model/go"
|
||||||
"google.golang.org/grpc"
|
"google.golang.org/grpc"
|
||||||
|
@ -49,7 +49,7 @@ func removeFile(fileName string) {
|
||||||
func TestAddPeer(t *testing.T) {
|
func TestAddPeer(t *testing.T) {
|
||||||
// ctx := context.Background()
|
// ctx := context.Background()
|
||||||
ctx := stop.NewDebug()
|
ctx := stop.NewDebug()
|
||||||
args := MakeDefaultTestArgs()
|
args := server.MakeDefaultTestArgs()
|
||||||
|
|
||||||
tests := []struct {
|
tests := []struct {
|
||||||
name string
|
name string
|
||||||
|
@ -108,7 +108,7 @@ func TestAddPeer(t *testing.T) {
|
||||||
func TestPeerWriter(t *testing.T) {
|
func TestPeerWriter(t *testing.T) {
|
||||||
// ctx := context.Background()
|
// ctx := context.Background()
|
||||||
ctx := stop.NewDebug()
|
ctx := stop.NewDebug()
|
||||||
args := MakeDefaultTestArgs()
|
args := server.MakeDefaultTestArgs()
|
||||||
args.DisableWritePeers = false
|
args.DisableWritePeers = false
|
||||||
|
|
||||||
tests := []struct {
|
tests := []struct {
|
||||||
|
@ -165,8 +165,8 @@ func TestPeerWriter(t *testing.T) {
|
||||||
func TestAddPeerEndpoint(t *testing.T) {
|
func TestAddPeerEndpoint(t *testing.T) {
|
||||||
// ctx := context.Background()
|
// ctx := context.Background()
|
||||||
ctx := stop.NewDebug()
|
ctx := stop.NewDebug()
|
||||||
args := MakeDefaultTestArgs()
|
args := server.MakeDefaultTestArgs()
|
||||||
args2 := MakeDefaultTestArgs()
|
args2 := server.MakeDefaultTestArgs()
|
||||||
args2.Port = "50052"
|
args2.Port = "50052"
|
||||||
|
|
||||||
tests := []struct {
|
tests := []struct {
|
||||||
|
@ -237,9 +237,9 @@ func TestAddPeerEndpoint(t *testing.T) {
|
||||||
func TestAddPeerEndpoint2(t *testing.T) {
|
func TestAddPeerEndpoint2(t *testing.T) {
|
||||||
// ctx := context.Background()
|
// ctx := context.Background()
|
||||||
ctx := stop.NewDebug()
|
ctx := stop.NewDebug()
|
||||||
args := MakeDefaultTestArgs()
|
args := server.MakeDefaultTestArgs()
|
||||||
args2 := MakeDefaultTestArgs()
|
args2 := server.MakeDefaultTestArgs()
|
||||||
args3 := MakeDefaultTestArgs()
|
args3 := server.MakeDefaultTestArgs()
|
||||||
args2.Port = "50052"
|
args2.Port = "50052"
|
||||||
args3.Port = "50053"
|
args3.Port = "50053"
|
||||||
|
|
||||||
|
@ -319,9 +319,9 @@ func TestAddPeerEndpoint2(t *testing.T) {
|
||||||
func TestAddPeerEndpoint3(t *testing.T) {
|
func TestAddPeerEndpoint3(t *testing.T) {
|
||||||
// ctx := context.Background()
|
// ctx := context.Background()
|
||||||
ctx := stop.NewDebug()
|
ctx := stop.NewDebug()
|
||||||
args := MakeDefaultTestArgs()
|
args := server.MakeDefaultTestArgs()
|
||||||
args2 := MakeDefaultTestArgs()
|
args2 := server.MakeDefaultTestArgs()
|
||||||
args3 := MakeDefaultTestArgs()
|
args3 := server.MakeDefaultTestArgs()
|
||||||
args2.Port = "50052"
|
args2.Port = "50052"
|
||||||
args3.Port = "50053"
|
args3.Port = "50053"
|
||||||
|
|
||||||
|
@ -409,9 +409,9 @@ func TestAddPeerEndpoint3(t *testing.T) {
|
||||||
func TestUDPServer(t *testing.T) {
|
func TestUDPServer(t *testing.T) {
|
||||||
// ctx := context.Background()
|
// ctx := context.Background()
|
||||||
ctx := stop.NewDebug()
|
ctx := stop.NewDebug()
|
||||||
args := MakeDefaultTestArgs()
|
args := server.MakeDefaultTestArgs()
|
||||||
args.DisableStartUDP = false
|
args.DisableStartUDP = false
|
||||||
args2 := MakeDefaultTestArgs()
|
args2 := server.MakeDefaultTestArgs()
|
||||||
args2.Port = "50052"
|
args2.Port = "50052"
|
||||||
args2.DisableStartUDP = false
|
args2.DisableStartUDP = false
|
||||||
|
|
||||||
|
|
|
@ -47,7 +47,7 @@ func tcpRead(conn net.Conn) ([]byte, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
func TestNotifierServer(t *testing.T) {
|
func TestNotifierServer(t *testing.T) {
|
||||||
args := MakeDefaultTestArgs()
|
args := server.MakeDefaultTestArgs()
|
||||||
// ctx := context.Background()
|
// ctx := context.Background()
|
||||||
ctx := stop.NewDebug()
|
ctx := stop.NewDebug()
|
||||||
hub := server.MakeHubServer(ctx, args)
|
hub := server.MakeHubServer(ctx, args)
|
||||||
|
|
|
@ -58,7 +58,7 @@ func TestSearch(t *testing.T) {
|
||||||
|
|
||||||
ctx := context.Background()
|
ctx := context.Background()
|
||||||
stopGroup := stop.NewDebug()
|
stopGroup := stop.NewDebug()
|
||||||
args := MakeDefaultTestArgs()
|
args := server.MakeDefaultTestArgs()
|
||||||
hubServer := server.MakeHubServer(stopGroup, args)
|
hubServer := server.MakeHubServer(stopGroup, args)
|
||||||
req := &pb.SearchRequest{
|
req := &pb.SearchRequest{
|
||||||
Text: "asdf",
|
Text: "asdf",
|
||||||
|
|
|
@ -11,7 +11,7 @@ import (
|
||||||
|
|
||||||
// TestUDPPing tests UDPPing correctness against prod server.
|
// TestUDPPing tests UDPPing correctness against prod server.
|
||||||
func TestUDPPing(t *testing.T) {
|
func TestUDPPing(t *testing.T) {
|
||||||
args := MakeDefaultTestArgs()
|
args := server.MakeDefaultTestArgs()
|
||||||
args.DisableStartUDP = true
|
args.DisableStartUDP = true
|
||||||
|
|
||||||
tests := []struct {
|
tests := []struct {
|
||||||
|
|
Loading…
Reference in a new issue