From 25443b1a3386d6f2c2660a7ca54a4ef7d73f3b7d Mon Sep 17 00:00:00 2001 From: Jan-Philipp Litza Date: Wed, 1 Dec 2021 15:29:16 +0100 Subject: [PATCH] Fix ssh_spec tests (#2415) The behavior was changed in 8179f485, but the tests weren't updated. --- spec/input/ssh_spec.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spec/input/ssh_spec.rb b/spec/input/ssh_spec.rb index 8228ac289..1eab99712 100644 --- a/spec/input/ssh_spec.rb +++ b/spec/input/ssh_spec.rb @@ -30,7 +30,7 @@ @node.expects(:model).returns(model).at_least_once proxy = mock - Net::SSH::Proxy::Command.expects(:new).with("ssh test.com -W %h:%p").returns(proxy) + Net::SSH::Proxy::Command.expects(:new).with("ssh test.com -W [%h]:%p").returns(proxy) Net::SSH.expects(:start).with('93.184.216.34', 'alma', port: 22, verify_host_key: Oxidized.config.input.ssh.secure ? :always : :never, keepalive: true, @@ -61,7 +61,7 @@ @node.expects(:model).returns(model).at_least_once proxy = mock - Net::SSH::Proxy::Command.expects(:new).with("ssh test.com -W %h:%p").returns(proxy) + Net::SSH::Proxy::Command.expects(:new).with("ssh test.com -W [%h]:%p").returns(proxy) Net::SSH.expects(:start).with('example.com', 'alma', port: 22, verify_host_key: Oxidized.config.input.ssh.secure ? :always : :never, keepalive: true,