diff options
author | Carl Hörberg <carl.hoerberg@gmail.com> | 2015-05-26 12:16:05 +0200 |
---|---|---|
committer | Carl Hörberg <carl.hoerberg@gmail.com> | 2015-05-26 12:16:05 +0200 |
commit | bcd43b74090b732bfd0e31b5792b7ff9539a7d0f (patch) | |
tree | 198267d83fbf26e54a5964a030494a5457c3a4a3 /test | |
parent | fb96947672031fafa75a79f91c5bc9412b9b62ad (diff) | |
download | net-ssh-bcd43b74090b732bfd0e31b5792b7ff9539a7d0f.tar.gz |
Fix Socket.tcp stub in session_test
Diffstat (limited to 'test')
-rw-r--r-- | test/transport/test_session.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/transport/test_session.rb b/test/transport/test_session.rb index 6c267ec..50adeec 100644 --- a/test/transport/test_session.rb +++ b/test/transport/test_session.rb @@ -315,7 +315,7 @@ module Transport def session(options={}) @session ||= begin host = options.delete(:host) || "net.ssh.test" - TCPSocket.stubs(:open).with(host, options[:port] || 22, nil).returns(socket) + Socket.stubs(:tcp).with(host, options[:port] || 22, nil, nil, { connect_timeout: options[:timeout] }).returns(socket) Net::SSH::Transport::ServerVersion.stubs(:new).returns(server_version) Net::SSH::Transport::Algorithms.stubs(:new).returns(algorithms) |