Fileutils has a method ln_sf which forces the creation of a symlink
This commit is contained in:
parent
5f8fe542a0
commit
eb1cde19f9
@ -30,6 +30,12 @@ module FakeFS
|
|||||||
raise Errno::EEXIST, path if FileSystem.find(path)
|
raise Errno::EEXIST, path if FileSystem.find(path)
|
||||||
FileSystem.add(path, FakeSymlink.new(target))
|
FileSystem.add(path, FakeSymlink.new(target))
|
||||||
end
|
end
|
||||||
|
def ln_sf(target, path)
|
||||||
|
FileSystem.delete(path)
|
||||||
|
FileSystem.add(path, FakeSymlink.new(target))
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def cp(src, dest)
|
def cp(src, dest)
|
||||||
dst_file = FileSystem.find(dest)
|
dst_file = FileSystem.find(dest)
|
||||||
|
Loading…
Reference in New Issue
Block a user