1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-11-16 09:26:21 -05:00
v2fly/common/net/port_test.go
2021-02-17 04:31:50 +08:00

19 lines
292 B
Go

package net_test
import (
"testing"
. "github.com/v2fly/v2ray-core/v4/common/net"
)
func TestPortRangeContains(t *testing.T) {
portRange := &PortRange{
From: 53,
To: 53,
}
if !portRange.Contains(Port(53)) {
t.Error("expected port range containing 53, but actually not")
}
}