diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2017-03-07 14:24:22 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-07 14:24:22 -0800 |
commit | cf18bd311248fe8cc9278f0c4457b24fc4f40e9b (patch) | |
tree | 350f64b52996d1eaab49fefdd9f5eb175c2f6a47 | |
parent | aa16a9832c4c3d138cd43bbaadeccf1147834601 (diff) | |
parent | 227822c9134d3411a65f2e63c4368d9f9c091762 (diff) | |
download | chef-cf18bd311248fe8cc9278f0c4457b24fc4f40e9b.tar.gz |
Merge pull request #5873 from chef/lcg/knife-ssh-solaris-spec
fix spec for solaris 10
-rw-r--r-- | spec/functional/knife/ssh_spec.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/functional/knife/ssh_spec.rb b/spec/functional/knife/ssh_spec.rb index cfe28b862f..0de344f24e 100644 --- a/spec/functional/knife/ssh_spec.rb +++ b/spec/functional/knife/ssh_spec.rb @@ -1,6 +1,6 @@ # # Author:: Daniel DeLeo (<dan@chef.io>) -# Copyright:: Copyright 2010-2016, Chef Software Inc. +# Copyright:: Copyright 2010-2017, Chef Software Inc. # License:: Apache License, Version 2.0 # # Licensed under the Apache License, Version 2.0 (the "License"); @@ -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 => "#{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"), :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 => "#{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"), :keys_only => true }) @knife.run expect(@knife.config[:ssh_gateway_identity]).to eq("~/.ssh/aws-gateway.rsa") end |