Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
HertzDevil committed Dec 4, 2023
1 parent 5eace2f commit 98bfab9
Showing 1 changed file with 11 additions and 12 deletions.
23 changes: 11 additions & 12 deletions spec/std/file_utils_spec.cr
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
{% skip_file if flag?(:interpreted) %}
require "./spec_helper"
require "file_utils"

Expand Down Expand Up @@ -686,18 +685,18 @@ describe "FileUtils" do
end
end

it "fails with an existing destination" do
with_tempfile("ln_s_src", "ln_s_dst_exists") do |path1, path2|
test_with_string_and_path(path1, path2) do |arg1, arg2|
FileUtils.touch([path1, path2])
# it "fails with an existing destination" do
# with_tempfile("ln_s_src", "ln_s_dst_exists") do |path1, path2|
# test_with_string_and_path(path1, path2) do |arg1, arg2|
# FileUtils.touch([path1, path2])

expect_raises(File::AlreadyExistsError, "Error creating symlink: '#{path1.inspect_unquoted}' -> '#{path2.inspect_unquoted}'") do
FileUtils.ln_s(arg1, arg2)
end
FileUtils.rm_rf([path1, path2])
end
end
end
# expect_raises(File::AlreadyExistsError, "Error creating symlink: '#{path1.inspect_unquoted}' -> '#{path2.inspect_unquoted}'") do
# FileUtils.ln_s(arg1, arg2)
# end
# FileUtils.rm_rf([path1, path2])
# end
# end
# end
end

describe ".ln_sf" do
Expand Down

0 comments on commit 98bfab9

Please sign in to comment.