1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-06-28 18:25:23 +00:00
v2fly/transport/internet/system_dns_android_test.go
rurirei 2129c6e1e9
feat: update bootstrap_dns_android (#966)
* update with non_specified network

* remove wrongs

* add alternative bootstrapDialer

* do test

* Update dns_bootstrap_android_test.go

* example of alternative dialer

* public method

* move const

* Update dns_bootstrap_android_test.go

* no duplicated

* Rename infra/conf/dns_bootstrap_android.go to transport/internet/system_dns_android.go

* Update system_dns_android.go

* Update and rename infra/conf/dns_bootstrap_android_test.go to transport/internet/system_dns_android_test.go

* no imports

* Update system_dns_android.go

* Update system_dns_android_test.go

* create systemDNS

* Create system_dns_android.go

* Update system_dialer.go

* call Resolver on systemDialer

* create system_dns_test.go

* resolver.LookupIP params

* param fix

* noneed TestSystemDNSResolver

* revert: no specified resolver

* Delete system_dns.go

* android only

* android only test

* typo
2021-05-04 22:22:01 +01:00

16 lines
288 B
Go

// +build android
package internet
import (
"context"
"testing"
)
func TestDNSResolver(t *testing.T) {
resolver := NewDNSResolver()
if ips, err := resolver.LookupIP(context.Background(), "ip", "www.google.com"); err != nil {
t.Errorf("failed to lookupIP, %v, %v", ips, err)
}
}