mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-28 22:17:14 +00:00
Update tests to reflect that kubeadm taints should not override node taints
This commit is contained in:
parent
792195eaa5
commit
35615881e3
@ -82,11 +82,28 @@ func TestMarkMaster(t *testing.T) {
|
|||||||
"{}",
|
"{}",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"nothing missing but taint unwanted",
|
"has taint and no new taints wanted",
|
||||||
kubeadmconstants.LabelNodeRoleMaster,
|
kubeadmconstants.LabelNodeRoleMaster,
|
||||||
[]v1.Taint{kubeadmconstants.MasterTaint},
|
[]v1.Taint{
|
||||||
|
{
|
||||||
|
Key: "node.cloudprovider.kubernetes.io/uninitialized",
|
||||||
|
Effect: v1.TaintEffectNoSchedule,
|
||||||
|
},
|
||||||
|
},
|
||||||
nil,
|
nil,
|
||||||
"{\"spec\":{\"taints\":null}}",
|
"{}",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"has taint and should merge with wanted taint",
|
||||||
|
kubeadmconstants.LabelNodeRoleMaster,
|
||||||
|
[]v1.Taint{
|
||||||
|
{
|
||||||
|
Key: "node.cloudprovider.kubernetes.io/uninitialized",
|
||||||
|
Effect: v1.TaintEffectNoSchedule,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
[]v1.Taint{kubeadmconstants.MasterTaint},
|
||||||
|
"{\"spec\":{\"taints\":[{\"effect\":\"NoSchedule\",\"key\":\"node-role.kubernetes.io/master\"},{\"effect\":\"NoSchedule\",\"key\":\"node.cloudprovider.kubernetes.io/uninitialized\"}]}}",
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user