aboutsummaryrefslogtreecommitdiff
path: root/plugin
diff options
context:
space:
mode:
authorGravatar Zou Nengren <zounengren@cmss.chinamobile.com> 2020-07-13 23:26:43 +0800
committerGravatar GitHub <noreply@github.com> 2020-07-13 08:26:43 -0700
commit20c4f28a5c791f7ef3ba4a8c72553de073448bd3 (patch)
treef01588b3e7848468dac7730221794bdb033d7aa8 /plugin
parentfc054620af142e9c9e93d4a03316907934987b4d (diff)
downloadcoredns-20c4f28a5c791f7ef3ba4a8c72553de073448bd3.tar.gz
coredns-20c4f28a5c791f7ef3ba4a8c72553de073448bd3.tar.zst
coredns-20c4f28a5c791f7ef3ba4a8c72553de073448bd3.zip
remove TestProxyClose (#4005)
Signed-off-by: zounengren <zounengren@cmss.chinamobile.com>
Diffstat (limited to 'plugin')
-rw-r--r--plugin/forward/proxy_test.go26
1 files changed, 0 insertions, 26 deletions
diff --git a/plugin/forward/proxy_test.go b/plugin/forward/proxy_test.go
index b962f561b..b6b755a66 100644
--- a/plugin/forward/proxy_test.go
+++ b/plugin/forward/proxy_test.go
@@ -13,32 +13,6 @@ import (
"github.com/miekg/dns"
)
-func TestProxyClose(t *testing.T) {
- s := dnstest.NewServer(func(w dns.ResponseWriter, r *dns.Msg) {
- ret := new(dns.Msg)
- ret.SetReply(r)
- w.WriteMsg(ret)
- })
- defer s.Close()
-
- req := new(dns.Msg)
- req.SetQuestion("example.org.", dns.TypeA)
- state := request.Request{W: &test.ResponseWriter{}, Req: req}
- ctx := context.TODO()
-
- for i := 0; i < 100; i++ {
- p := NewProxy(s.Addr, transport.DNS)
- p.start(hcInterval)
-
- go func() { p.Connect(ctx, state, options{}) }()
- go func() { p.Connect(ctx, state, options{forceTCP: true}) }()
- go func() { p.Connect(ctx, state, options{}) }()
- go func() { p.Connect(ctx, state, options{forceTCP: true}) }()
-
- p.stop()
- }
-}
-
func TestProxy(t *testing.T) {
s := dnstest.NewServer(func(w dns.ResponseWriter, r *dns.Msg) {
ret := new(dns.Msg)