sadanand48 commented on a change in pull request #1555:
URL: https://github.com/apache/ozone/pull/1555#discussion_r533080860
##########
File path:
hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/fs/ozone/TestOzoneFileSystem.java
##########
@@ -776,4 +784,59 @@ public void testRenameToTrashEnabled() throws Exception {
// Cleanup
o3fs.delete(trashRoot, true);
}
+ /**
+ * 1.Move a Key to Trash
+ * 2.Verify that the key gets deleted by the trash emptier.
+ * @throws Exception
+ */
+
+ public void testTrash() throws Exception {
+ String testKeyName = "testKey2";
+ Path path = new Path(OZONE_URI_DELIMITER, testKeyName);
+ ContractTestUtils.touch(fs, path);
+ Assert.assertTrue(trash.getConf().getClass(
+ "fs.trash.classname", TrashPolicy.class).
+ isAssignableFrom(TrashPolicyOzone.class));
+ Assert.assertEquals(trash.getConf().getInt("fs.trash.interval", 0), 1);
Review comment:
done
##########
File path:
hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/fs/ozone/TestOzoneFileSystem.java
##########
@@ -776,4 +784,59 @@ public void testRenameToTrashEnabled() throws Exception {
// Cleanup
o3fs.delete(trashRoot, true);
}
+ /**
+ * 1.Move a Key to Trash
+ * 2.Verify that the key gets deleted by the trash emptier.
+ * @throws Exception
+ */
+
+ public void testTrash() throws Exception {
+ String testKeyName = "testKey2";
+ Path path = new Path(OZONE_URI_DELIMITER, testKeyName);
+ ContractTestUtils.touch(fs, path);
+ Assert.assertTrue(trash.getConf().getClass(
+ "fs.trash.classname", TrashPolicy.class).
+ isAssignableFrom(TrashPolicyOzone.class));
+ Assert.assertEquals(trash.getConf().getInt("fs.trash.interval", 0), 1);
+ Assert.assertEquals(trash.getConf().getInt("fs.trash.checkpoint.interval",
Review comment:
done
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]