mirror of
https://github.com/ruby/ruby.git
synced 2025-08-23 04:55:21 +02:00
* lib/fileutils.rb: handle ENOENT error with symlink targeted to
non-exists file. [ruby-dev:45933] [Bug #6716] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46783 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
94bbd10ea7
commit
c2eac0e78c
3 changed files with 20 additions and 3 deletions
|
@ -445,6 +445,12 @@ class TestFileUtils < Test::Unit::TestCase
|
|||
assert_raise(Errno::ELOOP) {
|
||||
mv 'tmp/symlink', 'tmp/symlink'
|
||||
}
|
||||
# unexist symlink
|
||||
File.symlink 'xxx', 'tmp/src'
|
||||
assert_nothing_raised {
|
||||
mv 'tmp/src', 'tmp/dest'
|
||||
}
|
||||
assert_equal true, File.symlink?('tmp/dest')
|
||||
end if have_symlink?
|
||||
|
||||
def test_mv_pathname
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue