plugin/kubernetes: check for bare zone query (#1692)
* check for bare zone query * check for bare type query
This commit is contained in:
parent
9a7e487a5a
commit
51e1442bd9
5 changed files with 49 additions and 1 deletions
|
@ -19,6 +19,12 @@ func TestParseRequest(t *testing.T) {
|
|||
{"*.any.*.any.svc.inter.webs.test.", "*.any..*.any.svc"},
|
||||
// A request of endpoint
|
||||
{"1-2-3-4.webs.mynamespace.svc.inter.webs.test.", "*.*.1-2-3-4.webs.mynamespace.svc"},
|
||||
// bare zone
|
||||
{"inter.webs.test.", "....."},
|
||||
// bare svc type
|
||||
{"svc.inter.webs.test.", "....."},
|
||||
// bare pod type
|
||||
{"pod.inter.webs.test.", "....."},
|
||||
}
|
||||
for i, tc := range tests {
|
||||
m := new(dns.Msg)
|
||||
|
@ -53,4 +59,4 @@ func TestParseInvalidRequest(t *testing.T) {
|
|||
}
|
||||
}
|
||||
|
||||
const zone = "intern.webs.tests."
|
||||
const zone = "inter.webs.tests."
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue