diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2016-02-23 10:45:15 -0800 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2016-02-23 10:45:15 -0800 |
commit | 271d3e4f91e3d158c9112512ac75d0ca51fc928d (patch) | |
tree | 5beb5e5588db43ecac46f38725cabf5e573fd1d6 /spec/unit/knife | |
parent | aa7e0e05395823c66b30f1a810d1720aea3b6d72 (diff) | |
download | chef-271d3e4f91e3d158c9112512ac75d0ca51fc928d.tar.gz |
Autofixing new Perf cops in 0.37.2
6 Performance/Casecmp
18 Performance/Detect
1 Performance/RangeInclude
27 Performance/RedundantBlockCall
6 Performance/RedundantMatch
5 Performance/RedundantMerge
18 Performance/StringReplacement
Diffstat (limited to 'spec/unit/knife')
-rw-r--r-- | spec/unit/knife/cookbook_site_download_spec.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/unit/knife/cookbook_site_download_spec.rb b/spec/unit/knife/cookbook_site_download_spec.rb index d7f26f2f2e..d283bd417f 100644 --- a/spec/unit/knife/cookbook_site_download_spec.rb +++ b/spec/unit/knife/cookbook_site_download_spec.rb @@ -28,7 +28,7 @@ describe Chef::Knife::CookbookSiteDownload do @stderr = StringIO.new @cookbook_api_url = "https://supermarket.chef.io/api/v1/cookbooks" @version = "1.0.2" - @version_us = @version.gsub ".", "_" + @version_us = @version.tr ".", "_" @current_data = { "deprecated" => false, "latest_version" => "#{@cookbook_api_url}/apache2/versions/#{@version_us}", "replacement" => "other_apache2" } @@ -120,7 +120,7 @@ describe Chef::Knife::CookbookSiteDownload do context "downloading a cookbook of a specific version" do before do @version = "1.0.1" - @version_us = @version.gsub ".", "_" + @version_us = @version.tr ".", "_" @cookbook_data = { "version" => @version, "file" => "http://example.com/apache2_#{@version_us}.tgz" } @temp_file = double(:path => "/tmp/apache2_#{@version_us}.tgz") |