smengcl commented on code in PR #6128:
URL: https://github.com/apache/ozone/pull/6128#discussion_r1473653095
##########
hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/ozone/om/snapshot/TestOzoneManagerSnapshotAcl.java:
##########
@@ -382,6 +383,69 @@ public void testGetAclWithNotAllowedUser(BucketLayout
bucketLayout)
assertDoesNotThrow(() -> ozoneManager.getAcl(keyObj));
}
+ @ParameterizedTest
+ @EnumSource(BucketLayout.class)
+ public void testLookupKeyWithAllowedUserForPrefixAcl(BucketLayout
bucketLayout) throws Exception {
+ UserGroupInformation.setLoginUser(UGI1);
+
+ createVolume();
+
+ final OzoneVolume volume = objectStore.getVolume(volumeName);
+ createBucket(bucketLayout, volume);
+
+ final OzoneBucket bucket = volume.getBucket(bucketName);
+
+ setDefaultPrefixAcls();
+
+ createKey(bucket);
+
+ setDefaultVolumeAcls();
+ setDefaultBucketAcls();
+
+ createSnapshot();
+
+ final OmKeyArgs snapshotKeyArgs = getOmKeyArgs(true);
+ assertDoesNotThrow(() -> ozoneManager.lookupKey(snapshotKeyArgs));
+ }
+
+ @ParameterizedTest
+ @EnumSource(BucketLayout.class)
+ public void testLookupKeyWithNotAllowedUserForPrefixAcl(BucketLayout
bucketLayout) throws Exception {
Review Comment:
ok i'm fine with either way
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]