From 1f782754446a045dde6f031e3dc3ff6f73cd79cb Mon Sep 17 00:00:00 2001 From: Robert Cheramy Date: Tue, 30 Apr 2024 16:45:41 +0200 Subject: [PATCH] Update ip of example.com in ssh-test Close #3145 The A-record of example.com was changed from 93.184.216.34 to 93.184.215.14, so our test failed. I updated the IP-Adress in the ssh-test. I could have added an automatic resolution in the test, but I don't think the IP of example.com will change too often, so I kept it simple. A comment should help to find the problem quickly next time. I'm not documenting this in CHANGELOG.md as it is only relevant for developpers and not for our users. --- spec/input/ssh_spec.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/spec/input/ssh_spec.rb b/spec/input/ssh_spec.rb index 41c2b2669..ad42a3374 100644 --- a/spec/input/ssh_spec.rb +++ b/spec/input/ssh_spec.rb @@ -15,6 +15,8 @@ describe "#connect" do it "should use proxy command when proxy host given and connect by ip if resolve_dns is true" do + # If this test fails, check it exemple.com stil resolves to 93.184.215.14 + # If not, update Net::SSH.expects(:start).with('93.184.215.14'... below Oxidized.config.resolve_dns = true @node = Oxidized::Node.new(name: 'example.com', input: 'ssh', @@ -44,7 +46,7 @@ auth_methods: %w[none publickey password], proxy: proxy } - Net::SSH.expects(:start).with('93.184.216.34', 'alma', ssh_options) + Net::SSH.expects(:start).with('93.184.215.14', 'alma', ssh_options) ssh.instance_variable_set("@exec", true) ssh.connect(@node)