diff --git a/utils_test.go b/utils_test.go index fcc51b8..bab2979 100644 --- a/utils_test.go +++ b/utils_test.go @@ -13,6 +13,13 @@ func TestGetCurrentIP(t *testing.T) { } else { t.Log("IP is:" + ip) } + + conf = &Settings{Socks5Proxy: "localhost:8899", IPUrl: "http://members.3322.org/dyndns/getip"} + ip, err := GetCurrentIP(conf) + + if ip != "" && err == nil { + t.Error("should return error") + } } func TestCheckSettings(t *testing.T) {