[ 
https://issues.apache.org/jira/browse/IO-693?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17244564#comment-17244564
 ] 

Gary D. Gregory edited comment on IO-693 at 12/5/20, 7:25 PM:
--------------------------------------------------------------

[~xpyrus]

Thanks for your patience. Let's take these one API at a time.

Hm, I just added 
{{org.apache.commons.io.FileUtilsTestCase.testForceDeleteReadOnlyFile()}}

May you please add a test that shows your failure?


was (Author: garydgregory):
[~xpyrus]

Thanks for your patience. Let's take these one API at a time.

Hm, I just added 
{{org.apache.commons.io.FileUtilsTestCase.testForceDeleteReadOnlyFile()}}

> FileUtils.deleteDirectory & PathUtils.deleteDirectory are behaving differently
> ------------------------------------------------------------------------------
>
>                 Key: IO-693
>                 URL: https://issues.apache.org/jira/browse/IO-693
>             Project: Commons IO
>          Issue Type: Improvement
>          Components: Utilities
>    Affects Versions: 2.8.0
>            Reporter: Robert Seidel
>            Priority: Major
>
> # With the newly added PathUtils, the behavior of FileUtils.deleteDirectory 
> has changed. Now nio is used instead of the old File.delete. The problem is, 
> nio does not delete files with read only attribute and failes instead.
>  # The interface of FileUtils was not extended to provide the possibility to 
> use a DeleteOption, so I guess, if someone wants to remove "all" files, then 
> PathUtils should be used. But here comes the next problem, 
> FileUtils.deleteDirectory checks for the existence (in opposite to its 
> javadoc), where PathUtils.deleteDirectory does not. Thats very inconsistent.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to