fix tests
This commit is contained in:
parent
56d90dfa70
commit
355847faa4
@ -128,7 +128,7 @@ func BenchmarkTCPDirectForwardParallel(b *testing.B) {
|
||||
}
|
||||
|
||||
func udpDirectForwardRoundtrip(t *testing.T, host string, data []byte) error {
|
||||
ln, err := UDPDirectForwardListener("localhost:0", 0)
|
||||
ln, err := UDPDirectForwardListener("localhost:0", nil)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@ -172,7 +172,7 @@ func BenchmarkUDPDirectForward(b *testing.B) {
|
||||
sendData := make([]byte, 128)
|
||||
rand.Read(sendData)
|
||||
|
||||
ln, err := UDPDirectForwardListener("localhost:0", 0)
|
||||
ln, err := UDPDirectForwardListener("localhost:0", nil)
|
||||
if err != nil {
|
||||
b.Error(err)
|
||||
}
|
||||
@ -207,7 +207,7 @@ func BenchmarkUDPDirectForwardParallel(b *testing.B) {
|
||||
sendData := make([]byte, 128)
|
||||
rand.Read(sendData)
|
||||
|
||||
ln, err := UDPDirectForwardListener("localhost:0", 0)
|
||||
ln, err := UDPDirectForwardListener("localhost:0", nil)
|
||||
if err != nil {
|
||||
b.Error(err)
|
||||
}
|
||||
@ -279,7 +279,7 @@ func TestTCPRemoteForward(t *testing.T) {
|
||||
}
|
||||
|
||||
func udpRemoteForwardRoundtrip(t *testing.T, host string, data []byte) error {
|
||||
ln, err := UDPRemoteForwardListener("localhost:0", nil, 0)
|
||||
ln, err := UDPRemoteForwardListener("localhost:0", nil, nil)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
@ -302,7 +302,7 @@ func BenchmarkSSProxyParallel(b *testing.B) {
|
||||
|
||||
func shadowUDPRoundtrip(t *testing.T, host string, data []byte,
|
||||
clientInfo *url.Userinfo, serverInfo *url.Userinfo) error {
|
||||
ln, err := ShadowUDPListener("localhost:0", serverInfo, 0)
|
||||
ln, err := ShadowUDPListener("localhost:0", serverInfo, nil)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@ -361,7 +361,7 @@ func BenchmarkShadowUDP(b *testing.B) {
|
||||
sendData := make([]byte, 128)
|
||||
rand.Read(sendData)
|
||||
|
||||
ln, err := ShadowUDPListener("localhost:0", url.UserPassword("chacha20-ietf", "123456"), 0)
|
||||
ln, err := ShadowUDPListener("localhost:0", url.UserPassword("chacha20-ietf", "123456"), nil)
|
||||
if err != nil {
|
||||
b.Error(err)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user