diff options
author | hsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-05-15 01:22:36 +0000 |
---|---|---|
committer | hsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-05-15 01:22:36 +0000 |
commit | 6f9609867cdd4bf965465d0aabe0e8e6c665e9c0 (patch) | |
tree | e2ccfc78ad8d67aa8284ae8426d9f6afc12683b7 /test/fileutils | |
parent | ee1b07b675ec034f8a91065598c4848a0a99eee0 (diff) |
Merge fileutils-1.1.0.
This version was migrated JRuby paches.
https://github.com/ruby/fileutils/pull/18
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63425 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/fileutils')
-rw-r--r-- | test/fileutils/test_fileutils.rb | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/test/fileutils/test_fileutils.rb b/test/fileutils/test_fileutils.rb index c531af1569..f2600005f5 100644 --- a/test/fileutils/test_fileutils.rb +++ b/test/fileutils/test_fileutils.rb @@ -233,7 +233,7 @@ class TestFileUtils < Test::Unit::TestCase def test_assert_output_lines assert_raise(MiniTest::Assertion) { - Timeout.timeout(0.1) { + Timeout.timeout(0.5) { assert_output_lines([]) { Thread.current.report_on_exception = false raise "ok" @@ -834,13 +834,15 @@ class TestFileUtils < Test::Unit::TestCase check_singleton :ln_s TARGETS.each do |fname| - fname = "../#{fname}" - lnfname = 'tmp/lnsdest' - ln_s fname, lnfname - assert FileTest.symlink?(lnfname), 'not symlink' - assert_equal fname, File.readlink(lnfname) - ensure - rm_f lnfname + begin + fname = "../#{fname}" + lnfname = 'tmp/lnsdest' + ln_s fname, lnfname + assert FileTest.symlink?(lnfname), 'not symlink' + assert_equal fname, File.readlink(lnfname) + ensure + rm_f lnfname + end end end if have_symlink? and !no_broken_symlink? @@ -1613,6 +1615,10 @@ class TestFileUtils < Test::Unit::TestCase check_singleton :cd end + def test_cd_result + assert_equal 42, cd('.') { 42 } + end + def test_chdir check_singleton :chdir end |