1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* test/ruby/test_file.rb (TestFile#test_realpath_encoding): rescue Errno::EACCES

and skip the testcase because it'll be raised on Windows always unless the
  runner doesn't have the administrator privilege.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53673 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
usa 2016-01-27 12:00:07 +00:00
parent 63710b73b2
commit cf3c1bfead

View file

@ -268,7 +268,11 @@ class TestFile < Test::Unit::TestCase
realdir = File.realpath(tmpdir) realdir = File.realpath(tmpdir)
open(File.join(tmpdir, tst), "w") {} open(File.join(tmpdir, tst), "w") {}
a = File.join(tmpdir, "x") a = File.join(tmpdir, "x")
File.symlink(tst, a) begin
File.symlink(tst, a)
rescue Errno::EACCES
skip "need privilege"
end
assert_equal(File.join(realdir, tst), File.realpath(a)) assert_equal(File.join(realdir, tst), File.realpath(a))
File.unlink(a) File.unlink(a)