Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows: make File.delete remove symlink directories, not Dir.delete #13224

Merged

Conversation

HertzDevil
Copy link
Contributor

Resolves #13194.

spec/std/dir_spec.cr Outdated Show resolved Hide resolved
spec/std/file_spec.cr Outdated Show resolved Hide resolved
src/crystal/system/win32/dir.cr Outdated Show resolved Hide resolved
src/dir.cr Outdated Show resolved Hide resolved
Comment on lines +165 to +167
expect_raises(File::Error) do
Dir.delete(symlink_path)
end
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suppose this could be good enough, but checking the actual error message would be nice. 💅

@straight-shoota straight-shoota added this to the 1.8.0 milestone Apr 5, 2023
@straight-shoota straight-shoota merged commit 4d3385a into crystal-lang:master Apr 6, 2023
@HertzDevil HertzDevil deleted the bug/windows-delete-symlink-dir branch April 6, 2023 14:41
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Deletion of symbolic link directories is inconsistent across systems
2 participants