зеркало из https://github.com/github/ruby.git
test_ftp.rb: loosen timeout for Travis osx
https://travis-ci.org/ruby/ruby/jobs/454798071 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65723 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
158562dabb
Коммит
2a477e0e44
|
@ -377,7 +377,7 @@ class FTPTest < Test::Unit::TestCase
|
|||
begin
|
||||
begin
|
||||
ftp = Net::FTP.new
|
||||
ftp.read_timeout = 0.2
|
||||
ftp.read_timeout = 1.0
|
||||
ftp.connect(SERVER_ADDR, server.port)
|
||||
ftp.login
|
||||
assert_match(/\AUSER /, commands.shift)
|
||||
|
@ -386,7 +386,7 @@ class FTPTest < Test::Unit::TestCase
|
|||
assert_equal(nil, commands.shift)
|
||||
ensure
|
||||
ftp.close
|
||||
assert_equal(0.2, ftp.read_timeout)
|
||||
assert_equal(1.0, ftp.read_timeout)
|
||||
end
|
||||
ensure
|
||||
server.close
|
||||
|
@ -662,7 +662,7 @@ class FTPTest < Test::Unit::TestCase
|
|||
sock.print("150 Opening BINARY mode data connection for foo (#{binary_data.size} bytes)\r\n")
|
||||
conn = TCPSocket.new(host, port)
|
||||
binary_data.scan(/.{1,1024}/nm) do |s|
|
||||
sleep(0.1)
|
||||
sleep(0.2)
|
||||
conn.print(s)
|
||||
end
|
||||
conn.shutdown(Socket::SHUT_WR)
|
||||
|
@ -673,7 +673,7 @@ class FTPTest < Test::Unit::TestCase
|
|||
begin
|
||||
begin
|
||||
ftp = Net::FTP.new
|
||||
ftp.read_timeout = 0.2
|
||||
ftp.read_timeout = 1.0
|
||||
ftp.connect(SERVER_ADDR, server.port)
|
||||
ftp.login
|
||||
assert_match(/\AUSER /, commands.shift)
|
||||
|
|
Загрузка…
Ссылка в новой задаче