mirror of
https://github.com/v2fly/v2ray-core
synced 2024-02-27 03:18:06 +00:00
replace TypedMessage with anypb.Any
This commit is contained in:
@@ -3,6 +3,7 @@ package scenarios
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
"io"
|
||||
"strings"
|
||||
"testing"
|
||||
@@ -44,10 +45,10 @@ func TestCommanderRemoveHandler(t *testing.T) {
|
||||
clientPort := tcp.PickPort()
|
||||
cmdPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&commander.Config{
|
||||
Tag: "api",
|
||||
Service: []*serial.TypedMessage{
|
||||
Service: []*anypb.Any{
|
||||
serial.ToTypedMessage(&command.Config{}),
|
||||
},
|
||||
}),
|
||||
@@ -142,10 +143,10 @@ func TestCommanderAddRemoveUser(t *testing.T) {
|
||||
cmdPort := tcp.PickPort()
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&commander.Config{
|
||||
Tag: "api",
|
||||
Service: []*serial.TypedMessage{
|
||||
Service: []*anypb.Any{
|
||||
serial.ToTypedMessage(&command.Config{}),
|
||||
},
|
||||
}),
|
||||
@@ -210,7 +211,7 @@ func TestCommanderAddRemoveUser(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&policy.Config{
|
||||
Level: map[uint32]*policy.Policy{
|
||||
0: {
|
||||
@@ -323,11 +324,11 @@ func TestCommanderStats(t *testing.T) {
|
||||
cmdPort := tcp.PickPort()
|
||||
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&stats.Config{}),
|
||||
serial.ToTypedMessage(&commander.Config{
|
||||
Tag: "api",
|
||||
Service: []*serial.TypedMessage{
|
||||
Service: []*anypb.Any{
|
||||
serial.ToTypedMessage(&statscmd.Config{}),
|
||||
},
|
||||
}),
|
||||
|
||||
@@ -2,6 +2,7 @@ package scenarios
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
@@ -30,7 +31,7 @@ func TestResolveIP(t *testing.T) {
|
||||
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&dns.Config{
|
||||
Hosts: map[string]*net.IPOrDomain{
|
||||
"google.com": net.NewIPOrDomain(dest.Address),
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package scenarios
|
||||
|
||||
import (
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
@@ -35,7 +36,7 @@ func TestDokodemoTCP(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -68,7 +69,7 @@ func TestDokodemoTCP(t *testing.T) {
|
||||
clientPort := uint32(tcp.PickPort())
|
||||
clientPortRange := uint32(5)
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
|
||||
@@ -2,6 +2,7 @@ package scenarios
|
||||
|
||||
import (
|
||||
"context"
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
@@ -424,7 +425,7 @@ func TestBlackhole(t *testing.T) {
|
||||
ProxySettings: serial.ToTypedMessage(&blackhole.Config{}),
|
||||
},
|
||||
},
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&router.Config{
|
||||
Rule: []*router.RoutingRule{
|
||||
{
|
||||
@@ -599,7 +600,7 @@ func TestDomainSniffing(t *testing.T) {
|
||||
ProxySettings: serial.ToTypedMessage(&freedom.Config{}),
|
||||
},
|
||||
},
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&router.Config{
|
||||
Rule: []*router.RoutingRule{
|
||||
{
|
||||
@@ -658,7 +659,7 @@ func TestDialV2Ray(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -690,7 +691,7 @@ func TestDialV2Ray(t *testing.T) {
|
||||
}
|
||||
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&dispatcher.Config{}),
|
||||
serial.ToTypedMessage(&proxyman.InboundConfig{}),
|
||||
serial.ToTypedMessage(&proxyman.OutboundConfig{}),
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package scenarios
|
||||
|
||||
import (
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
"io"
|
||||
"testing"
|
||||
"time"
|
||||
@@ -54,7 +55,7 @@ func TestVMessClosing(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&policy.Config{
|
||||
Level: map[uint32]*policy.Policy{
|
||||
0: {
|
||||
@@ -93,7 +94,7 @@ func TestVMessClosing(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&policy.Config{
|
||||
Level: map[uint32]*policy.Policy{
|
||||
0: {
|
||||
@@ -165,7 +166,7 @@ func TestZeroBuffer(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&policy.Config{
|
||||
Level: map[uint32]*policy.Policy{
|
||||
0: {
|
||||
@@ -207,7 +208,7 @@ func TestZeroBuffer(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package scenarios
|
||||
|
||||
import (
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
@@ -41,7 +42,7 @@ func TestReverseProxy(t *testing.T) {
|
||||
reversePort := tcp.PickPort()
|
||||
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&reverse.Config{
|
||||
PortalConfig: []*reverse.PortalConfig{
|
||||
{
|
||||
@@ -110,7 +111,7 @@ func TestReverseProxy(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&reverse.Config{
|
||||
BridgeConfig: []*reverse.BridgeConfig{
|
||||
{
|
||||
@@ -212,7 +213,7 @@ func TestReverseProxyLongRunning(t *testing.T) {
|
||||
reversePort := tcp.PickPort()
|
||||
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Warning,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -295,7 +296,7 @@ func TestReverseProxyLongRunning(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Warning,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package scenarios
|
||||
|
||||
import (
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
@@ -120,7 +121,7 @@ func TestShadowsocksAES256GCMTCP(t *testing.T) {
|
||||
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -150,7 +151,7 @@ func TestShadowsocksAES256GCMTCP(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -217,7 +218,7 @@ func TestShadowsocksAES128GCMUDP(t *testing.T) {
|
||||
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -247,7 +248,7 @@ func TestShadowsocksAES128GCMUDP(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -313,7 +314,7 @@ func TestShadowsocksAES128GCMUDPMux(t *testing.T) {
|
||||
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -343,7 +344,7 @@ func TestShadowsocksAES128GCMUDPMux(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package scenarios
|
||||
|
||||
import (
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
@@ -194,7 +195,7 @@ func TestSocksBridageUDPWithRouting(t *testing.T) {
|
||||
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&router.Config{
|
||||
Rule: []*router.RoutingRule{
|
||||
{
|
||||
|
||||
@@ -2,6 +2,7 @@ package scenarios
|
||||
|
||||
import (
|
||||
"crypto/x509"
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
"runtime"
|
||||
"testing"
|
||||
"time"
|
||||
@@ -47,7 +48,7 @@ func TestSimpleTLSConnection(t *testing.T) {
|
||||
Listen: net.NewIPOrDomain(net.LocalHostIP),
|
||||
StreamSettings: &internet.StreamConfig{
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
Certificate: []*tls.Certificate{tls.ParseCertificate(cert.MustGenerate(nil))},
|
||||
}),
|
||||
@@ -109,7 +110,7 @@ func TestSimpleTLSConnection(t *testing.T) {
|
||||
SenderSettings: serial.ToTypedMessage(&proxyman.SenderConfig{
|
||||
StreamSettings: &internet.StreamConfig{
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
AllowInsecure: true,
|
||||
}),
|
||||
@@ -160,7 +161,7 @@ func TestAutoIssuingCertificate(t *testing.T) {
|
||||
Listen: net.NewIPOrDomain(net.LocalHostIP),
|
||||
StreamSettings: &internet.StreamConfig{
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
Certificate: []*tls.Certificate{{
|
||||
Certificate: certPEM,
|
||||
@@ -226,7 +227,7 @@ func TestAutoIssuingCertificate(t *testing.T) {
|
||||
SenderSettings: serial.ToTypedMessage(&proxyman.SenderConfig{
|
||||
StreamSettings: &internet.StreamConfig{
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
ServerName: "v2fly.org",
|
||||
Certificate: []*tls.Certificate{{
|
||||
@@ -271,7 +272,7 @@ func TestTLSOverKCP(t *testing.T) {
|
||||
StreamSettings: &internet.StreamConfig{
|
||||
Protocol: internet.TransportProtocol_MKCP,
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
Certificate: []*tls.Certificate{tls.ParseCertificate(cert.MustGenerate(nil))},
|
||||
}),
|
||||
@@ -334,7 +335,7 @@ func TestTLSOverKCP(t *testing.T) {
|
||||
StreamSettings: &internet.StreamConfig{
|
||||
Protocol: internet.TransportProtocol_MKCP,
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
AllowInsecure: true,
|
||||
}),
|
||||
@@ -373,7 +374,7 @@ func TestTLSOverWebSocket(t *testing.T) {
|
||||
StreamSettings: &internet.StreamConfig{
|
||||
Protocol: internet.TransportProtocol_WebSocket,
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
Certificate: []*tls.Certificate{tls.ParseCertificate(cert.MustGenerate(nil))},
|
||||
}),
|
||||
@@ -442,7 +443,7 @@ func TestTLSOverWebSocket(t *testing.T) {
|
||||
},
|
||||
},
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
AllowInsecure: true,
|
||||
}),
|
||||
@@ -494,7 +495,7 @@ func TestHTTP2(t *testing.T) {
|
||||
},
|
||||
},
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
Certificate: []*tls.Certificate{tls.ParseCertificate(cert.MustGenerate(nil))},
|
||||
}),
|
||||
@@ -566,7 +567,7 @@ func TestHTTP2(t *testing.T) {
|
||||
},
|
||||
},
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
AllowInsecure: true,
|
||||
}),
|
||||
@@ -610,7 +611,7 @@ func TestSimpleTLSConnectionPinned(t *testing.T) {
|
||||
Listen: net.NewIPOrDomain(net.LocalHostIP),
|
||||
StreamSettings: &internet.StreamConfig{
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
Certificate: []*tls.Certificate{certificate},
|
||||
}),
|
||||
@@ -672,7 +673,7 @@ func TestSimpleTLSConnectionPinned(t *testing.T) {
|
||||
SenderSettings: serial.ToTypedMessage(&proxyman.SenderConfig{
|
||||
StreamSettings: &internet.StreamConfig{
|
||||
SecurityType: serial.GetMessageType(&tls.Config{}),
|
||||
SecuritySettings: []*serial.TypedMessage{
|
||||
SecuritySettings: []*anypb.Any{
|
||||
serial.ToTypedMessage(&tls.Config{
|
||||
AllowInsecure: true,
|
||||
PinnedPeerCertificateChainSha256: [][]byte{certHash},
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package scenarios
|
||||
|
||||
import (
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
"os"
|
||||
"runtime"
|
||||
"testing"
|
||||
@@ -259,7 +260,7 @@ func TestVMessQuic(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -306,7 +307,7 @@ func TestVMessQuic(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package scenarios
|
||||
|
||||
import (
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
"os"
|
||||
"testing"
|
||||
"time"
|
||||
@@ -38,7 +39,7 @@ func TestVMessDynamicPort(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -93,7 +94,7 @@ func TestVMessDynamicPort(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -157,7 +158,7 @@ func TestVMessGCM(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -190,7 +191,7 @@ func TestVMessGCM(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -263,7 +264,7 @@ func TestVMessGCMReadv(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -296,7 +297,7 @@ func TestVMessGCMReadv(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -372,7 +373,7 @@ func TestVMessGCMUDP(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -405,7 +406,7 @@ func TestVMessGCMUDP(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -475,7 +476,7 @@ func TestVMessChacha20(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -508,7 +509,7 @@ func TestVMessChacha20(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -579,7 +580,7 @@ func TestVMessNone(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -612,7 +613,7 @@ func TestVMessNone(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -682,7 +683,7 @@ func TestVMessKCP(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := udp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -718,7 +719,7 @@ func TestVMessKCP(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -793,7 +794,7 @@ func TestVMessKCPLarge(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := udp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -848,7 +849,7 @@ func TestVMessKCPLarge(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -946,7 +947,7 @@ func TestVMessGCMMux(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -979,7 +980,7 @@ func TestVMessGCMMux(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -1065,7 +1066,7 @@ func TestVMessGCMMuxUDP(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -1099,7 +1100,7 @@ func TestVMessGCMMuxUDP(t *testing.T) {
|
||||
clientPort := tcp.PickPort()
|
||||
clientUDPPort := udp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -1196,7 +1197,7 @@ func TestVMessZero(t *testing.T) {
|
||||
userID := protocol.NewID(uuid.New())
|
||||
serverPort := tcp.PickPort()
|
||||
serverConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
@@ -1229,7 +1230,7 @@ func TestVMessZero(t *testing.T) {
|
||||
|
||||
clientPort := tcp.PickPort()
|
||||
clientConfig := &core.Config{
|
||||
App: []*serial.TypedMessage{
|
||||
App: []*anypb.Any{
|
||||
serial.ToTypedMessage(&log.Config{
|
||||
ErrorLogLevel: clog.Severity_Debug,
|
||||
ErrorLogType: log.LogType_Console,
|
||||
|
||||
Reference in New Issue
Block a user