Project

General

Profile

Bug #272

test_chdir failed when Dir.tmpdir is symlink

Added by znz (Kazuhiro NISHIYAMA) about 12 years ago. Updated over 9 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Target version:
-
ruby -v:
Backport:
[ruby-dev:35481]

Description

=begin
Dir.tmpdirが返すディレクトリがsymlinkのときにtest_chdirが失敗します。

% ln -s /tmp $HOME/symlink-tmpdir
% env TMPDIR=$HOME/symlink-tmpdir ruby-trunk -v test/ruby/test_dir.rb
ruby 1.9.0 (2008-07-14 revision 18060) [i686-linux]
Loaded suite test/ruby/test_dir
Started
.test/ruby/test_dir.rb:111: warning: conflicting chdir during another chdir block
F..........
Finished in 0.0631458779999999 seconds.

1) Failure:
test_chdir(TestDir)
[test/ruby/test_dir.rb:112:in block in test_chdir'
test/ruby/test_dir.rb:109:in
chdir'
test/ruby/test_dir.rb:109:in `test_chdir']:
<"/home/kazu/symlink-tmpdir/test_dir20080714-13467-1l19gzu"> expected but was
<"/tmp/test_dir20080714-13467-1l19gzu">.

12 tests, 78 assertions, 1 failures, 0 errors
=end

Also available in: Atom PDF