diff options
author | Thom May <thom@may.lt> | 2017-03-09 15:07:46 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-09 15:07:46 +0000 |
commit | 761000d63e200f5b24e5b8d1a9e3233d3782040b (patch) | |
tree | e5300b004527e34e4af7bf9a03531da5171eac7a | |
parent | e8df359c36539b308242ea523c04780287cd9eab (diff) | |
parent | e66ed8e864c1c002f7bf613543aae8740cd87cd5 (diff) | |
download | chef-761000d63e200f5b24e5b8d1a9e3233d3782040b.tar.gz |
Merge pull request #5887 from chef/tm/fix_sol10_harder
Ensure that there are no pesky // in our paths
-rw-r--r-- | spec/functional/knife/ssh_spec.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/functional/knife/ssh_spec.rb b/spec/functional/knife/ssh_spec.rb index 0de344f24e..dbd7b92c6c 100644 --- a/spec/functional/knife/ssh_spec.rb +++ b/spec/functional/knife/ssh_spec.rb @@ -254,7 +254,7 @@ describe Chef::Knife::Ssh do end it "uses the ssh_gateway_identity file" do - expect(@knife.session).to receive(:via).with("ec2.public_hostname", "user", { :keys => File.expand_path("#{ENV['HOME']}/.ssh/aws-gateway.rsa"), :keys_only => true }) + expect(@knife.session).to receive(:via).with("ec2.public_hostname", "user", { :keys => File.expand_path("#{ENV['HOME']}/.ssh/aws-gateway.rsa").squeeze("/"), :keys_only => true }) @knife.run expect(@knife.config[:ssh_gateway_identity]).to eq("~/.ssh/aws-gateway.rsa") end @@ -268,7 +268,7 @@ describe Chef::Knife::Ssh do end it "uses the ssh_gateway_identity file" do - expect(@knife.session).to receive(:via).with("ec2.public_hostname", "user", { :keys => File.expand_path("#{ENV['HOME']}/.ssh/aws-gateway.rsa"), :keys_only => true }) + expect(@knife.session).to receive(:via).with("ec2.public_hostname", "user", { :keys => File.expand_path("#{ENV['HOME']}/.ssh/aws-gateway.rsa").squeeze("/"), :keys_only => true }) @knife.run expect(@knife.config[:ssh_gateway_identity]).to eq("~/.ssh/aws-gateway.rsa") end |