Lehel44 commented on a change in pull request #5190:
URL: https://github.com/apache/nifi/pull/5190#discussion_r679941927
##########
File path:
nifi-nar-bundles/nifi-azure-bundle/nifi-azure-processors/src/test/java/org/apache/nifi/processors/azure/storage/ITDeleteAzureDataLakeStorage.java
##########
@@ -35,15 +35,82 @@
public class ITDeleteAzureDataLakeStorage extends
AbstractAzureDataLakeStorageIT {
+ private static final boolean FILE = true;
+ private static final boolean DIRECTORY = false;
+
@Override
protected Class<? extends Processor> getProcessorClass() {
return DeleteAzureDataLakeStorage.class;
}
+ @Test
+ public void testDeleteDirectoryWithFiles() {
+ // GIVEN
+ String directory = "TestDirectory";
+ String filename = "testFile.txt";
+ String fileContent = "AzureFileContent";
+ String inputFlowFileContent = "InputFlowFileContent";
+
+ createDirectoryAndUploadFile(directory, filename, fileContent);
+
+ // WHEN
+ // THEN
+ testSuccessfulDelete(fileSystemName, directory, filename,
inputFlowFileContent, inputFlowFileContent, DIRECTORY);
+ }
+
+ @Test
+ public void testDeleteEmptyDirectoryAsFolder() {
Review comment:
Yes, originally you could delete an empty folder if you provided it in
the filename property. Now we have introduced a new property to chose between
file and folder deletion. So that currently we can delete an empty directory as
a FILE or as a FOLDER. I think I will rename the other test case, too. Or shall
I add a comment somewhere about this? It's not trivial at all.
--
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]