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

Use shorter filenames to avoid sockaddr_un size limitation.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50214 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
akr 2015-04-10 11:52:29 +00:00
parent 0ad3abe1f1
commit 6f636adad0

View file

@ -54,7 +54,7 @@ class TestFileExhaustive < Test::Unit::TestCase
end
def make_tmp_filename(prefix)
"#{@dir}/#{prefix}#{File.basename(__FILE__)}.#{$$}.test"
"#{@dir}/#{prefix}.#{$$}.test"
end
def test_path
@ -173,7 +173,7 @@ class TestFileExhaustive < Test::Unit::TestCase
assert_file.not_socket?(@file)
assert_file.not_socket?(@nofile)
if defined? UNIXServer
socket = make_tmp_filename("socket")
socket = make_tmp_filename("s")
UNIXServer.open(socket) {|sock|
assert_file.socket?(socket)
}
@ -1003,7 +1003,7 @@ class TestFileExhaustive < Test::Unit::TestCase
make_fifo fifo
end
if defined? UNIXServer
socket = make_tmp_filename("socket")
socket = make_tmp_filename("s")
UNIXServer.open(socket).close
end
[@dir, @file, @zerofile, @symlinkfile, @hardlinkfile, fifo, socket].compact.each do |f|
@ -1129,7 +1129,7 @@ class TestFileExhaustive < Test::Unit::TestCase
assert(!(File::Stat.new(@dir).socket?))
assert(!(File::Stat.new(@file).socket?))
if defined? UNIXServer
socket = make_tmp_filename("socket")
socket = make_tmp_filename("s")
UNIXServer.open(socket) {|sock|
assert(File::Stat.new(socket).socket?)
}