diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2019-07-03 12:26:05 -0700 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2019-07-05 12:40:44 -0700 |
commit | 4978a9a8a402477f3b35f43404701d6a5cf26fa1 (patch) | |
tree | 7f336c1fa29d7bdb50f8a6e0a2e5943fbb32ba51 /spec/unit/knife | |
parent | 2833651dcf54db5ba8e92746b479ebafa897b275 (diff) | |
download | chef-4978a9a8a402477f3b35f43404701d6a5cf26fa1.tar.gz |
Style/EmptyLiteral
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Diffstat (limited to 'spec/unit/knife')
-rw-r--r-- | spec/unit/knife/client_bulk_delete_spec.rb | 4 | ||||
-rw-r--r-- | spec/unit/knife/cookbook_bulk_delete_spec.rb | 2 | ||||
-rw-r--r-- | spec/unit/knife/key_create_spec.rb | 2 | ||||
-rw-r--r-- | spec/unit/knife/key_edit_spec.rb | 2 | ||||
-rw-r--r-- | spec/unit/knife/key_list_spec.rb | 2 | ||||
-rw-r--r-- | spec/unit/knife/node_bulk_delete_spec.rb | 2 | ||||
-rw-r--r-- | spec/unit/knife/role_bulk_delete_spec.rb | 2 | ||||
-rw-r--r-- | spec/unit/knife/supermarket_install_spec.rb | 2 |
8 files changed, 9 insertions, 9 deletions
diff --git a/spec/unit/knife/client_bulk_delete_spec.rb b/spec/unit/knife/client_bulk_delete_spec.rb index 21bac9d0c0..770ba8762f 100644 --- a/spec/unit/knife/client_bulk_delete_spec.rb +++ b/spec/unit/knife/client_bulk_delete_spec.rb @@ -42,7 +42,7 @@ describe Chef::Knife::ClientBulkDelete do let(:nonvalidator_client_names) { %w{tim dan stephen} } let(:nonvalidator_clients) do - clients = Hash.new + clients = {} nonvalidator_client_names.each do |client_name| client = Chef::ApiClientV1.new @@ -56,7 +56,7 @@ describe Chef::Knife::ClientBulkDelete do let(:validator_client_names) { %w{myorg-validator} } let(:validator_clients) do - clients = Hash.new + clients = {} validator_client_names.each do |validator_client_name| validator_client = Chef::ApiClientV1.new diff --git a/spec/unit/knife/cookbook_bulk_delete_spec.rb b/spec/unit/knife/cookbook_bulk_delete_spec.rb index c8c1873081..d01213227b 100644 --- a/spec/unit/knife/cookbook_bulk_delete_spec.rb +++ b/spec/unit/knife/cookbook_bulk_delete_spec.rb @@ -31,7 +31,7 @@ describe Chef::Knife::CookbookBulkDelete do allow(@knife.ui).to receive(:stdout).and_return(@stdout) allow(@knife.ui).to receive(:stderr).and_return(@stderr) allow(@knife.ui).to receive(:confirm).and_return(true) - @cookbooks = Hash.new + @cookbooks = {} %w{cheezburger pizza lasagna}.each do |cookbook_name| cookbook = Chef::CookbookVersion.new(cookbook_name) @cookbooks[cookbook_name] = cookbook diff --git a/spec/unit/knife/key_create_spec.rb b/spec/unit/knife/key_create_spec.rb index fcbfd40381..6437ba2bcd 100644 --- a/spec/unit/knife/key_create_spec.rb +++ b/spec/unit/knife/key_create_spec.rb @@ -84,7 +84,7 @@ Tfuc9dUYsFjptWYrV6pfEQ+bgo1OGBXORBFcFL+2D7u9JYquKrMgosznHoEkQNLo 0wIDAQAB -----END PUBLIC KEY-----" end - let(:config) { Hash.new } + let(:config) { {} } let(:actor) { "charmander" } let(:ui) { instance_double("Chef::Knife::UI") } diff --git a/spec/unit/knife/key_edit_spec.rb b/spec/unit/knife/key_edit_spec.rb index 7c409f5ea0..1f8067c160 100644 --- a/spec/unit/knife/key_edit_spec.rb +++ b/spec/unit/knife/key_edit_spec.rb @@ -86,7 +86,7 @@ Tfuc9dUYsFjptWYrV6pfEQ+bgo1OGBXORBFcFL+2D7u9JYquKrMgosznHoEkQNLo 0wIDAQAB -----END PUBLIC KEY-----" end - let(:config) { Hash.new } + let(:config) { {} } let(:actor) { "charmander" } let(:keyname) { "charmander-key" } let(:ui) { instance_double("Chef::Knife::UI") } diff --git a/spec/unit/knife/key_list_spec.rb b/spec/unit/knife/key_list_spec.rb index e221a4da72..c65a11b08c 100644 --- a/spec/unit/knife/key_list_spec.rb +++ b/spec/unit/knife/key_list_spec.rb @@ -73,7 +73,7 @@ describe "key list commands that inherit knife" do end describe Chef::Knife::KeyList do - let(:config) { Hash.new } + let(:config) { {} } let(:actor) { "charmander" } let(:ui) { instance_double("Chef::Knife::UI") } diff --git a/spec/unit/knife/node_bulk_delete_spec.rb b/spec/unit/knife/node_bulk_delete_spec.rb index b955b5de6c..b97df004a3 100644 --- a/spec/unit/knife/node_bulk_delete_spec.rb +++ b/spec/unit/knife/node_bulk_delete_spec.rb @@ -28,7 +28,7 @@ describe Chef::Knife::NodeBulkDelete do @stdout = StringIO.new allow(@knife.ui).to receive(:stdout).and_return(@stdout) allow(@knife.ui).to receive(:confirm).and_return(true) - @nodes = Hash.new + @nodes = {} %w{adam brent jacob}.each do |node_name| @nodes[node_name] = "http://localhost:4000/nodes/#{node_name}" end diff --git a/spec/unit/knife/role_bulk_delete_spec.rb b/spec/unit/knife/role_bulk_delete_spec.rb index c39a8ec652..07a9b484c4 100644 --- a/spec/unit/knife/role_bulk_delete_spec.rb +++ b/spec/unit/knife/role_bulk_delete_spec.rb @@ -29,7 +29,7 @@ describe Chef::Knife::RoleBulkDelete do @stdout = StringIO.new allow(@knife.ui).to receive(:stdout).and_return(@stdout) allow(@knife.ui).to receive(:confirm).and_return(true) - @roles = Hash.new + @roles = {} %w{dev staging production}.each do |role_name| role = Chef::Role.new role.name(role_name) diff --git a/spec/unit/knife/supermarket_install_spec.rb b/spec/unit/knife/supermarket_install_spec.rb index d891de9268..801fb74802 100644 --- a/spec/unit/knife/supermarket_install_spec.rb +++ b/spec/unit/knife/supermarket_install_spec.rb @@ -23,7 +23,7 @@ describe Chef::Knife::SupermarketInstall do let(:knife) { Chef::Knife::SupermarketInstall.new } let(:stdout) { StringIO.new } let(:stderr) { StringIO.new } - let(:downloader) { Hash.new } + let(:downloader) { {} } let(:archive) { double(Mixlib::Archive, extract: true) } let(:repo) do double(sanity_check: true, reset_to_default_state: true, |