mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-07-18 04:54:54 +00:00
test(certificates): Add ratcheting test for CSR conditions
This commit is contained in:
@@ -177,6 +177,11 @@ func testValidateUpdateForDeclarative(t *testing.T, apiVersion string) {
|
||||
),
|
||||
subresources: []string{"/approval"}, // Can only modify Approved and Denied conditions on /approval subresource
|
||||
},
|
||||
"ratcheting: allow existing duplicate types - valid": {
|
||||
old: makeValidCSR(withApprovedCondition(), withApprovedCondition(), withDeniedCondition(), withDeniedCondition()),
|
||||
update: makeValidCSR(withDeniedCondition(), withDeniedCondition(), withApprovedCondition(), withApprovedCondition()),
|
||||
subresources: []string{"/status"},
|
||||
},
|
||||
}
|
||||
|
||||
for k, tc := range testCases {
|
||||
|
||||
Reference in New Issue
Block a user