diff options
Diffstat (limited to 'spec/unit/client_spec.rb')
-rw-r--r-- | spec/unit/client_spec.rb | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/spec/unit/client_spec.rb b/spec/unit/client_spec.rb index 001be10e0b..0e72a285af 100644 --- a/spec/unit/client_spec.rb +++ b/spec/unit/client_spec.rb @@ -179,12 +179,12 @@ describe Chef::Client do context "when an override run list is given" do it "permits spaces in overriding run list" do - Chef::Client.new(nil, :override_runlist => "role[a], role[b]") + Chef::Client.new(nil, override_runlist: "role[a], role[b]") end describe "calling run" do include_examples "a successful client run" do - let(:client_opts) { { :override_runlist => "recipe[override_recipe]" } } + let(:client_opts) { { override_runlist: "recipe[override_recipe]" } } def stub_for_sync_cookbooks # --Client#setup_run_context @@ -193,7 +193,7 @@ describe Chef::Client do expect_any_instance_of(Chef::CookbookSynchronizer).to receive(:sync_cookbooks) expect(Chef::ServerAPI).to receive(:new).with(Chef::Config[:chef_server_url], version_class: Chef::CookbookManifestVersions).and_return(http_cookbook_sync) expect(http_cookbook_sync).to receive(:post). - with("environments/_default/cookbook_versions", { :run_list => ["override_recipe"] }). + with("environments/_default/cookbook_versions", { run_list: ["override_recipe"] }). and_return({}) end @@ -218,7 +218,7 @@ describe Chef::Client do include_examples "a successful client run" do let(:new_runlist) { "recipe[new_run_list_recipe]" } - let(:client_opts) { { :runlist => new_runlist } } + let(:client_opts) { { runlist: new_runlist } } def stub_for_sync_cookbooks # --Client#setup_run_context @@ -227,7 +227,7 @@ describe Chef::Client do expect_any_instance_of(Chef::CookbookSynchronizer).to receive(:sync_cookbooks) expect(Chef::ServerAPI).to receive(:new).with(Chef::Config[:chef_server_url], version_class: Chef::CookbookManifestVersions).and_return(http_cookbook_sync) expect(http_cookbook_sync).to receive(:post). - with("environments/_default/cookbook_versions", { :run_list => ["new_run_list_recipe"] }). + with("environments/_default/cookbook_versions", { run_list: ["new_run_list_recipe"] }). and_return({}) end @@ -293,7 +293,7 @@ describe Chef::Client do describe "when handling run failures" do it "should remove the run_lock on failure of #load_node" do - @run_lock = double("Chef::RunLock", :acquire => true) + @run_lock = double("Chef::RunLock", acquire: true) allow(Chef::RunLock).to receive(:new).and_return(@run_lock) @events = double("Chef::EventDispatch::Dispatcher").as_null_object |