add test case of remote ip (#3964)

Signed-off-by: zounengren <zounengren@cmss.chinamobile.com>
This commit is contained in:
Zou Nengren
2020-06-24 05:37:00 +08:00
committed by GitHub
parent ba8a567e38
commit 55a33aa9d2
2 changed files with 23 additions and 5 deletions

View File

@@ -12,6 +12,7 @@ import (
"github.com/miekg/dns"
)
const name = "whoami"
// Whoami is a plugin that returns your IP address, port and the protocol used for connecting
// to CoreDNS.
type Whoami struct{}
@@ -55,4 +56,4 @@ func (wh Whoami) ServeDNS(ctx context.Context, w dns.ResponseWriter, r *dns.Msg)
}
// Name implements the Handler interface.
func (wh Whoami) Name() string { return "whoami" }
func (wh Whoami) Name() string { return name }