plugin/kubernetes: Allow only one k8s section (#1497)
* allow only one k8s section * add test
This commit is contained in:
parent
f636930c5c
commit
82854bf098
2 changed files with 18 additions and 1 deletions
|
@ -382,6 +382,20 @@ func TestKubernetesParse(t *testing.T) {
|
|||
fall.Zero,
|
||||
nil,
|
||||
},
|
||||
// More than one Kubernetes not allowed
|
||||
{
|
||||
`kubernetes coredns.local
|
||||
kubernetes cluster.local`,
|
||||
true,
|
||||
"only one kubernetes section allowed per server block",
|
||||
-1,
|
||||
0,
|
||||
defaultResyncPeriod,
|
||||
"",
|
||||
podModeDisabled,
|
||||
fall.Zero,
|
||||
nil,
|
||||
},
|
||||
}
|
||||
|
||||
for i, test := range tests {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue