|
|
@@ -37,6 +37,14 @@ func TestRouterConfig(t *testing.T) {
|
|
|
],
|
|
|
"outboundTag": "direct"
|
|
|
},
|
|
|
+ {
|
|
|
+ "type": "field",
|
|
|
+ "domains": [
|
|
|
+ "v2fly.org",
|
|
|
+ "github.com"
|
|
|
+ ],
|
|
|
+ "outboundTag": "direct"
|
|
|
+ },
|
|
|
{
|
|
|
"type": "field",
|
|
|
"ip": [
|
|
|
@@ -87,6 +95,21 @@ func TestRouterConfig(t *testing.T) {
|
|
|
Tag: "direct",
|
|
|
},
|
|
|
},
|
|
|
+ {
|
|
|
+ Domain: []*router.Domain{
|
|
|
+ {
|
|
|
+ Type: router.Domain_Plain,
|
|
|
+ Value: "v2fly.org",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ Type: router.Domain_Plain,
|
|
|
+ Value: "github.com",
|
|
|
+ },
|
|
|
+ },
|
|
|
+ TargetTag: &router.RoutingRule_Tag{
|
|
|
+ Tag: "direct",
|
|
|
+ },
|
|
|
+ },
|
|
|
{
|
|
|
Geoip: []*router.GeoIP{
|
|
|
{
|
|
|
@@ -145,6 +168,14 @@ func TestRouterConfig(t *testing.T) {
|
|
|
],
|
|
|
"outboundTag": "direct"
|
|
|
},
|
|
|
+ {
|
|
|
+ "type": "field",
|
|
|
+ "domains": [
|
|
|
+ "v2fly.org",
|
|
|
+ "github.com"
|
|
|
+ ],
|
|
|
+ "outboundTag": "direct"
|
|
|
+ },
|
|
|
{
|
|
|
"type": "field",
|
|
|
"ip": [
|
|
|
@@ -175,6 +206,21 @@ func TestRouterConfig(t *testing.T) {
|
|
|
Tag: "direct",
|
|
|
},
|
|
|
},
|
|
|
+ {
|
|
|
+ Domain: []*router.Domain{
|
|
|
+ {
|
|
|
+ Type: router.Domain_Plain,
|
|
|
+ Value: "v2fly.org",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ Type: router.Domain_Plain,
|
|
|
+ Value: "github.com",
|
|
|
+ },
|
|
|
+ },
|
|
|
+ TargetTag: &router.RoutingRule_Tag{
|
|
|
+ Tag: "direct",
|
|
|
+ },
|
|
|
+ },
|
|
|
{
|
|
|
Geoip: []*router.GeoIP{
|
|
|
{
|
|
|
@@ -209,6 +255,14 @@ func TestRouterConfig(t *testing.T) {
|
|
|
],
|
|
|
"outboundTag": "direct"
|
|
|
},
|
|
|
+ {
|
|
|
+ "type": "field",
|
|
|
+ "domains": [
|
|
|
+ "v2fly.org",
|
|
|
+ "github.com"
|
|
|
+ ],
|
|
|
+ "outboundTag": "direct"
|
|
|
+ },
|
|
|
{
|
|
|
"type": "field",
|
|
|
"ip": [
|
|
|
@@ -238,6 +292,21 @@ func TestRouterConfig(t *testing.T) {
|
|
|
Tag: "direct",
|
|
|
},
|
|
|
},
|
|
|
+ {
|
|
|
+ Domain: []*router.Domain{
|
|
|
+ {
|
|
|
+ Type: router.Domain_Plain,
|
|
|
+ Value: "v2fly.org",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ Type: router.Domain_Plain,
|
|
|
+ Value: "github.com",
|
|
|
+ },
|
|
|
+ },
|
|
|
+ TargetTag: &router.RoutingRule_Tag{
|
|
|
+ Tag: "direct",
|
|
|
+ },
|
|
|
+ },
|
|
|
{
|
|
|
Geoip: []*router.GeoIP{
|
|
|
{
|