@@ -359,6 +359,7 @@ public void testAttachPolicyToCatalogSufficientPrivileges() {
359359 doTestSufficientPrivilegeSets (
360360 List .of (
361361 Set .of (PolarisPrivilege .POLICY_ATTACH , PolarisPrivilege .CATALOG_ATTACH_POLICY ),
362+ Set .of (PolarisPrivilege .CATALOG_MANAGE_METADATA ),
362363 Set .of (PolarisPrivilege .CATALOG_MANAGE_CONTENT )),
363364 () -> newWrapper (Set .of (PRINCIPAL_ROLE1 )).attachPolicy (POLICY_NS1_1 , attachPolicyRequest ),
364365 () -> newWrapper (Set .of (PRINCIPAL_ROLE2 )).detachPolicy (POLICY_NS1_1 , detachPolicyRequest ),
@@ -405,6 +406,7 @@ public void testAttachPolicyToNamespaceSufficientPrivileges() {
405406 doTestSufficientPrivilegeSets (
406407 List .of (
407408 Set .of (PolarisPrivilege .POLICY_ATTACH , PolarisPrivilege .NAMESPACE_ATTACH_POLICY ),
409+ Set .of (PolarisPrivilege .CATALOG_MANAGE_METADATA ),
408410 Set .of (PolarisPrivilege .CATALOG_MANAGE_CONTENT )),
409411 () -> newWrapper (Set .of (PRINCIPAL_ROLE1 )).attachPolicy (POLICY_NS1_1 , attachPolicyRequest ),
410412 () -> newWrapper (Set .of (PRINCIPAL_ROLE2 )).detachPolicy (POLICY_NS1_1 , detachPolicyRequest ));
@@ -453,6 +455,7 @@ public void testAttachPolicyToTableSufficientPrivileges() {
453455 doTestSufficientPrivilegeSets (
454456 List .of (
455457 Set .of (PolarisPrivilege .POLICY_ATTACH , PolarisPrivilege .TABLE_ATTACH_POLICY ),
458+ Set .of (PolarisPrivilege .CATALOG_MANAGE_METADATA ),
456459 Set .of (PolarisPrivilege .CATALOG_MANAGE_CONTENT )),
457460 () -> newWrapper (Set .of (PRINCIPAL_ROLE1 )).attachPolicy (POLICY_NS1_1 , attachPolicyRequest ),
458461 () -> newWrapper (Set .of (PRINCIPAL_ROLE2 )).detachPolicy (POLICY_NS1_1 , detachPolicyRequest ));
@@ -507,6 +510,7 @@ public void testDetachPolicyFromCatalogSufficientPrivileges() {
507510 doTestSufficientPrivilegeSets (
508511 List .of (
509512 Set .of (PolarisPrivilege .POLICY_DETACH , PolarisPrivilege .CATALOG_DETACH_POLICY ),
513+ Set .of (PolarisPrivilege .CATALOG_MANAGE_METADATA ),
510514 Set .of (PolarisPrivilege .CATALOG_MANAGE_CONTENT )),
511515 () -> newWrapper (Set .of (PRINCIPAL_ROLE1 )).detachPolicy (POLICY_NS1_1 , detachPolicyRequest ),
512516 () ->
@@ -589,6 +593,7 @@ public void testDetachPolicyFromNamespaceSufficientPrivileges() {
589593 doTestSufficientPrivilegeSets (
590594 List .of (
591595 Set .of (PolarisPrivilege .POLICY_DETACH , PolarisPrivilege .NAMESPACE_DETACH_POLICY ),
596+ Set .of (PolarisPrivilege .CATALOG_MANAGE_METADATA ),
592597 Set .of (PolarisPrivilege .CATALOG_MANAGE_CONTENT )),
593598 () -> newWrapper (Set .of (PRINCIPAL_ROLE1 )).detachPolicy (POLICY_NS1_1 , detachPolicyRequest ),
594599 () ->
@@ -674,6 +679,7 @@ public void testDetachPolicyFromTableSufficientPrivileges() {
674679 doTestSufficientPrivilegeSets (
675680 List .of (
676681 Set .of (PolarisPrivilege .POLICY_DETACH , PolarisPrivilege .TABLE_DETACH_POLICY ),
682+ Set .of (PolarisPrivilege .CATALOG_MANAGE_METADATA ),
677683 Set .of (PolarisPrivilege .CATALOG_MANAGE_CONTENT )),
678684 () -> newWrapper (Set .of (PRINCIPAL_ROLE1 )).detachPolicy (POLICY_NS1_1 , detachPolicyRequest ),
679685 () ->
0 commit comments