anujmodi2021 commented on code in PR #7868: URL: https://github.com/apache/hadoop/pull/7868#discussion_r2282011563
########## hadoop-tools/hadoop-azure/src/test/java/org/apache/hadoop/fs/azurebfs/ITestAzureBlobFilesystemAcl.java: ########## @@ -56,33 +56,55 @@ * Test acl operations. */ public class ITestAzureBlobFilesystemAcl extends AbstractAbfsIntegrationTest { + Review Comment: So when the last time these changes were made the proper code-style was not set by whoever made these changes. In this PR these changes came in automatically due to importing the recommended code-style. Since this is the right thing to do, I feel like it might be okay to retain these changes. Anyways this is a small PR. ########## hadoop-tools/hadoop-azure/src/test/java/org/apache/hadoop/fs/azurebfs/ITestAzureBlobFilesystemAcl.java: ########## @@ -238,41 +276,46 @@ public void testModifyAclEntriesStickyBit() throws Exception { fs.modifyAclEntries(path, aclSpec); AclStatus s = fs.getAclStatus(path); AclEntry[] returned = s.getEntries().toArray(new AclEntry[0]); - assertArrayEquals(new AclEntry[]{aclEntry(ACCESS, USER, FOO, READ_EXECUTE), - aclEntry(ACCESS, GROUP, READ_EXECUTE), aclEntry(DEFAULT, USER, ALL), - aclEntry(DEFAULT, USER, FOO, READ_EXECUTE), aclEntry(DEFAULT, GROUP, READ_EXECUTE), - aclEntry(DEFAULT, MASK, READ_EXECUTE), aclEntry(DEFAULT, OTHER, NONE)}, + assertArrayEquals(new AclEntry[]{ + aclEntry(ACCESS, USER, FOO, READ_EXECUTE), + aclEntry(ACCESS, GROUP, READ_EXECUTE), + aclEntry(DEFAULT, USER, ALL), + aclEntry(DEFAULT, USER, FOO, READ_EXECUTE), + aclEntry(DEFAULT, GROUP, READ_EXECUTE), + aclEntry(DEFAULT, MASK, READ_EXECUTE), + aclEntry(DEFAULT, OTHER, NONE) + }, returned); assertPermission(fs, (short) 01750); } @Test public void testModifyAclEntriesPathNotFound() throws Exception { - Assertions.assertThrows(FileNotFoundException.class, () -> { - final AzureBlobFileSystem fs = this.getFileSystem(); - assumeTrue(getIsNamespaceEnabled(fs)); - path = new Path(testRoot, UUID.randomUUID().toString()); - List<AclEntry> aclSpec = Lists.newArrayList( - aclEntry(ACCESS, USER, ALL), - aclEntry(ACCESS, USER, FOO, ALL), - aclEntry(ACCESS, GROUP, READ_EXECUTE), - aclEntry(ACCESS, OTHER, NONE)); - fs.modifyAclEntries(path, aclSpec); - }); + assumeTrue(getIsNamespaceEnabled(getFileSystem())); + Assertions.assertThrows(FileNotFoundException.class, () -> { + final AzureBlobFileSystem fs = this.getFileSystem(); + path = new Path(testRoot, UUID.randomUUID().toString()); + List<AclEntry> aclSpec = Lists.newArrayList( + aclEntry(ACCESS, USER, ALL), + aclEntry(ACCESS, USER, FOO, ALL), + aclEntry(ACCESS, GROUP, READ_EXECUTE), + aclEntry(ACCESS, OTHER, NONE)); + fs.modifyAclEntries(path, aclSpec); + }); } @Test public void testModifyAclEntriesDefaultOnFile() throws Exception { - Assertions.assertThrows(Exception.class, () -> { - final AzureBlobFileSystem fs = this.getFileSystem(); - assumeTrue(getIsNamespaceEnabled(fs)); - path = new Path(testRoot, UUID.randomUUID().toString()); - fs.create(path).close(); - fs.setPermission(path, FsPermission.createImmutable((short) RW_R)); - List<AclEntry> aclSpec = Lists.newArrayList( - aclEntry(DEFAULT, USER, FOO, ALL)); - fs.modifyAclEntries(path, aclSpec); - }); + Assertions.assertThrows(Exception.class, () -> { + final AzureBlobFileSystem fs = this.getFileSystem(); Review Comment: Same as above -- 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: common-issues-unsubscr...@hadoop.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: common-issues-h...@hadoop.apache.org