diff options
author | 2017-02-08 12:53:55 -0500 | |
---|---|---|
committer | 2017-02-08 12:53:55 -0500 | |
commit | 353c1c648758a9854a494373575c355861ce3541 (patch) | |
tree | 4d541bf25fb3309bdf4288cdc49a2bb4c89ab45e /test/kubernetes_test.go | |
parent | fa1c90a479cce4666c32c4aae8728fc12f09980b (diff) | |
download | coredns-353c1c648758a9854a494373575c355861ce3541.tar.gz coredns-353c1c648758a9854a494373575c355861ce3541.tar.zst coredns-353c1c648758a9854a494373575c355861ce3541.zip |
Fix k8s chaining (#510)
* fix k8s next middleware chaining
* add chain to integration tests
* if nit
Diffstat (limited to 'test/kubernetes_test.go')
-rw-r--r-- | test/kubernetes_test.go | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/test/kubernetes_test.go b/test/kubernetes_test.go index fd38c2e03..a85dae446 100644 --- a/test/kubernetes_test.go +++ b/test/kubernetes_test.go @@ -225,6 +225,13 @@ var dnsTestCases = []test.Case{ test.TXT("dns-version.cluster.local. 28800 IN TXT \"1.0.0\""), }, }, + { + Qname: "next-in-chain.", Qtype: dns.TypeA, + Rcode: dns.RcodeSuccess, + Answer: []dns.RR{ + test.A("next-in-chain. 0 IN A 192.0.2.53"), + }, + }, } var dnsTestCasesPodsInsecure = []test.Case{ @@ -282,6 +289,13 @@ var dnsTestCasesCidrReverseZone = []test.Case{ test.PTR("115.0.0.10.in-addr.arpa. 303 IN PTR svc-c.test-1.svc.cluster.local."), }, }, + { + Qname: "next-in-chain.", Qtype: dns.TypeA, + Rcode: dns.RcodeSuccess, + Answer: []dns.RR{ + test.A("next-in-chain. 0 IN A 192.0.2.53"), + }, + }, } var dnsTestCasesPartialCidrReverseZone = []test.Case{ @@ -313,6 +327,13 @@ var dnsTestCasesPartialCidrReverseZone = []test.Case{ Rcode: dns.RcodeServerFailure, Answer: []dns.RR{}, }, + { + Qname: "next-in-chain.", Qtype: dns.TypeA, + Rcode: dns.RcodeSuccess, + Answer: []dns.RR{ + test.A("next-in-chain. 0 IN A 192.0.2.53"), + }, + }, } var dnsTestCasesAllNSExposed = []test.Case{ @@ -409,6 +430,9 @@ func TestKubernetesIntegration(t *testing.T) { namespaces test-1 pods disabled } + erratic . { + drop 0 + } ` doIntegrationTests(t, corefile, dnsTestCases) } @@ -445,6 +469,9 @@ func TestKubernetesIntegrationCidrReverseZone(t *testing.T) { namespaces test-1 cidrs 10.0.0.0/24 } + erratic . { + drop 0 + } ` doIntegrationTests(t, corefile, dnsTestCasesCidrReverseZone) } @@ -457,6 +484,9 @@ func TestKubernetesIntegrationPartialCidrReverseZone(t *testing.T) { namespaces test-1 cidrs 10.0.0.96/28 10.0.0.120/32 } + erratic . { + drop 0 + } ` doIntegrationTests(t, corefile, dnsTestCasesPartialCidrReverseZone) } |