fix failing UpsertBindingRules unit test (#15604)

UpsertBindingRules RPC changed in eacecb8,
validation happens after the ID check now, because we don't want validation to
fail for update payloads which may contain incomplete objects.
This commit is contained in:
Piotr Kazmierczak 2022-12-21 15:19:09 +01:00 committed by GitHub
parent 1528c09c9b
commit 3fd9fbeece
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -3147,6 +3147,7 @@ func TestACL_UpsertBindingRules(t *testing.T) {
// Create another ACL binding rule that will fail validation. Attempting to
// upsert this ensures the handler is triggering the validation function.
aclBindingRule2 := mock.ACLBindingRule()
aclBindingRule2.ID = ""
aclBindingRule2.BindType = ""
aclBindingRuleReq5 := &structs.ACLBindingRulesUpsertRequest{