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/http_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/http_spec.rb')
-rw-r--r-- | spec/unit/http_spec.rb | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/spec/unit/http_spec.rb b/spec/unit/http_spec.rb index ebb96d25e1..c35f8baaeb 100644 --- a/spec/unit/http_spec.rb +++ b/spec/unit/http_spec.rb @@ -16,11 +16,11 @@ # limitations under the License. # -require 'spec_helper' +require "spec_helper" -require 'chef/http' -require 'chef/http/basic_client' -require 'chef/http/socketless_chef_zero_client' +require "chef/http" +require "chef/http/basic_client" +require "chef/http/socketless_chef_zero_client" class Chef::HTTP public :create_url @@ -43,26 +43,26 @@ describe Chef::HTTP do describe "create_url" do - it 'should return a correctly formatted url 1/3 CHEF-5261' do - http = Chef::HTTP.new('http://www.getchef.com') - expect(http.create_url('api/endpoint')).to eql(URI.parse('http://www.getchef.com/api/endpoint')) + it "should return a correctly formatted url 1/3 CHEF-5261" do + http = Chef::HTTP.new("http://www.getchef.com") + expect(http.create_url("api/endpoint")).to eql(URI.parse("http://www.getchef.com/api/endpoint")) end - it 'should return a correctly formatted url 2/3 CHEF-5261' do - http = Chef::HTTP.new('http://www.getchef.com/') - expect(http.create_url('/organization/org/api/endpoint/')).to eql(URI.parse('http://www.getchef.com/organization/org/api/endpoint/')) + it "should return a correctly formatted url 2/3 CHEF-5261" do + http = Chef::HTTP.new("http://www.getchef.com/") + expect(http.create_url("/organization/org/api/endpoint/")).to eql(URI.parse("http://www.getchef.com/organization/org/api/endpoint/")) end - it 'should return a correctly formatted url 3/3 CHEF-5261' do - http = Chef::HTTP.new('http://www.getchef.com/organization/org///') - expect(http.create_url('///api/endpoint?url=http://foo.bar')).to eql(URI.parse('http://www.getchef.com/organization/org/api/endpoint?url=http://foo.bar')) + it "should return a correctly formatted url 3/3 CHEF-5261" do + http = Chef::HTTP.new("http://www.getchef.com/organization/org///") + expect(http.create_url("///api/endpoint?url=http://foo.bar")).to eql(URI.parse("http://www.getchef.com/organization/org/api/endpoint?url=http://foo.bar")) end # As per: https://github.com/opscode/chef/issues/2500 - it 'should treat scheme part of the URI in a case-insensitive manner' do + it "should treat scheme part of the URI in a case-insensitive manner" do http = Chef::HTTP.allocate # Calling Chef::HTTP::new sets @url, don't want that. - expect { http.create_url('HTTP://www1.chef.io/') }.not_to raise_error - expect(http.create_url('HTTP://www2.chef.io/')).to eql(URI.parse('http://www2.chef.io/')) + expect { http.create_url("HTTP://www1.chef.io/") }.not_to raise_error + expect(http.create_url("HTTP://www2.chef.io/")).to eql(URI.parse("http://www2.chef.io/")) end end # create_url @@ -117,7 +117,7 @@ describe Chef::HTTP do end it "retries the request 5 times" do - http.get('/') + http.get("/") end end |