mirror of
https://github.com/coredns/coredns.git
synced 2025-10-28 08:44:17 -04:00
Fix go fmt, go lint, and go vet issues (#494)
This fix fixes several `go fmt`, `go lint`, and `go vet` issues, to make goreportcard happy: https://goreportcard.com/report/github.com/miekg/coredns Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
This commit is contained in:
@@ -70,7 +70,7 @@ func TestEtcdStubAndProxyLookup(t *testing.T) {
|
||||
state := request.Request{W: &test.ResponseWriter{}, Req: new(dns.Msg)}
|
||||
resp, err := p.Lookup(state, "example.com.", dns.TypeA)
|
||||
if err != nil {
|
||||
t.Fatalf("Expected to receive reply, but didn't", err)
|
||||
t.Fatalf("Expected to receive reply, but didn't: %v", err)
|
||||
}
|
||||
if len(resp.Answer) == 0 {
|
||||
t.Fatalf("Expected to at least one RR in the answer section, got none")
|
||||
@@ -79,7 +79,7 @@ func TestEtcdStubAndProxyLookup(t *testing.T) {
|
||||
t.Errorf("Expected RR to A, got: %d", resp.Answer[0].Header().Rrtype)
|
||||
}
|
||||
if resp.Answer[0].(*dns.A).A.String() != "93.184.216.34" {
|
||||
t.Errorf("Expected 93.184.216.34, got: %d", resp.Answer[0].(*dns.A).A.String())
|
||||
t.Errorf("Expected 93.184.216.34, got: %s", resp.Answer[0].(*dns.A).A.String())
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user