plugin/kubernetes: check for bare zone query (#1692)

* check for bare zone query

* check for bare type query
This commit is contained in:
Chris O'Haver 2018-04-18 12:12:28 -04:00 committed by GitHub
parent 9a7e487a5a
commit 51e1442bd9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 49 additions and 1 deletions

View file

@ -35,6 +35,27 @@ var kubeApexCases = []test.Case{
test.A("ns.dns.cluster.local. 303 IN A 127.0.0.1"),
},
},
{
Qname: "cluster.local.", Qtype: dns.TypeA,
Rcode: dns.RcodeSuccess,
Ns: []dns.RR{
test.SOA("cluster.local. 303 IN SOA ns.dns.cluster.local. hostmaster.cluster.local. 1499347823 7200 1800 86400 60"),
},
},
{
Qname: "cluster.local.", Qtype: dns.TypeAAAA,
Rcode: dns.RcodeSuccess,
Ns: []dns.RR{
test.SOA("cluster.local. 303 IN SOA ns.dns.cluster.local. hostmaster.cluster.local. 1499347823 7200 1800 86400 60"),
},
},
{
Qname: "cluster.local.", Qtype: dns.TypeSRV,
Rcode: dns.RcodeSuccess,
Ns: []dns.RR{
test.SOA("cluster.local. 303 IN SOA ns.dns.cluster.local. hostmaster.cluster.local. 1499347823 7200 1800 86400 60"),
},
},
}
func TestServeDNSApex(t *testing.T) {