diff options
author | Thom May <thom@chef.io> | 2016-01-14 14:08:03 +0000 |
---|---|---|
committer | Thom May <thom@chef.io> | 2016-01-14 14:08:03 +0000 |
commit | 51cfbdc4d16739caac4d946fadbe678444aafe34 (patch) | |
tree | 56dfd8f1cd9fd933de27268b32402e955a43ac2b /spec/unit/application/knife_spec.rb | |
parent | 05064423057d4cf46f4713b81b08829cf6d20af6 (diff) | |
download | chef-51cfbdc4d16739caac4d946fadbe678444aafe34.tar.gz |
Use double quotes by default
This is an entirely mechanically generated (chefstyle -a) change, to go
along with chef/chefstyle#5 . We should pick something and use it
consistently, and my opinion is that double quotes are the appropriate
thing.
Diffstat (limited to 'spec/unit/application/knife_spec.rb')
-rw-r--r-- | spec/unit/application/knife_spec.rb | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/spec/unit/application/knife_spec.rb b/spec/unit/application/knife_spec.rb index 0fb25176f9..163489110f 100644 --- a/spec/unit/application/knife_spec.rb +++ b/spec/unit/application/knife_spec.rb @@ -15,7 +15,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -require 'spec_helper' +require "spec_helper" require "#{CHEF_SPEC_DATA}/knife_subcommand/test_yourself" describe Chef::Application::Knife do @@ -84,7 +84,7 @@ describe Chef::Application::Knife do describe "when given a path to the client key" do it "expands a relative path relative to the CWD" do - relative_path = '.chef/client.pem' + relative_path = ".chef/client.pem" allow(Dir).to receive(:pwd).and_return(CHEF_SPEC_DATA) with_argv(*%W{noop knife command -k #{relative_path}}) do expect(@knife).to receive(:exit).with(0) @@ -94,19 +94,19 @@ describe Chef::Application::Knife do end it "expands a ~/home/path to the correct full path" do - home_path = '~/.chef/client.pem' + home_path = "~/.chef/client.pem" with_argv(*%W{noop knife command -k #{home_path}}) do expect(@knife).to receive(:exit).with(0) @knife.run end - expect(Chef::Config[:client_key]).to eq(File.join(ENV['HOME'], '.chef/client.pem').gsub((File::ALT_SEPARATOR || '\\'), File::SEPARATOR)) + expect(Chef::Config[:client_key]).to eq(File.join(ENV["HOME"], ".chef/client.pem").gsub((File::ALT_SEPARATOR || '\\'), File::SEPARATOR)) end it "does not expand a full path" do full_path = if windows? - 'C:/chef/client.pem' + "C:/chef/client.pem" else - '/etc/chef/client.pem' + "/etc/chef/client.pem" end with_argv(*%W{noop knife command -k #{full_path}}) do expect(@knife).to receive(:exit).with(0) @@ -135,7 +135,7 @@ describe Chef::Application::Knife do expect(@knife).to receive(:exit).with(0) @knife.run end - expect(Chef::Config[:environment]).to eq('production') + expect(Chef::Config[:environment]).to eq("production") end it "should load the environment from the CLI options" do @@ -143,7 +143,7 @@ describe Chef::Application::Knife do expect(@knife).to receive(:exit).with(0) @knife.run end - expect(Chef::Config[:environment]).to eq('development') + expect(Chef::Config[:environment]).to eq("development") end it "should override the config file environment with the CLI environment" do @@ -152,7 +152,7 @@ describe Chef::Application::Knife do expect(@knife).to receive(:exit).with(0) @knife.run end - expect(Chef::Config[:environment]).to eq('override') + expect(Chef::Config[:environment]).to eq("override") end it "should override the config file environment with the CLI environment regardless of order" do @@ -161,7 +161,7 @@ describe Chef::Application::Knife do expect(@knife).to receive(:exit).with(0) @knife.run end - expect(Chef::Config[:environment]).to eq('override') + expect(Chef::Config[:environment]).to eq("override") end it "should run a sub command with the applications command line option prototype" do |