diff options
Diffstat (limited to 'spec/unit/node')
-rw-r--r-- | spec/unit/node/attribute_spec.rb | 6 | ||||
-rw-r--r-- | spec/unit/node/vivid_mash_spec.rb | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/spec/unit/node/attribute_spec.rb b/spec/unit/node/attribute_spec.rb index 557c469216..618a9bbe0e 100644 --- a/spec/unit/node/attribute_spec.rb +++ b/spec/unit/node/attribute_spec.rb @@ -22,8 +22,8 @@ require "chef/node/attribute" describe Chef::Node::Attribute do let(:events) { instance_double(Chef::EventDispatch::Dispatcher) } - let(:run_context) { instance_double(Chef::RunContext, :events => events) } - let(:node) { instance_double(Chef::Node, :run_context => run_context) } + let(:run_context) { instance_double(Chef::RunContext, events: events) } + let(:node) { instance_double(Chef::Node, run_context: run_context) } before(:each) do allow(events).to receive(:attribute_changed) @attribute_hash = @@ -184,7 +184,7 @@ describe Chef::Node::Attribute do [ :normal, :default, :override, :automatic ].each do |accessor| it "should set #{accessor}" do - na = Chef::Node::Attribute.new({ :normal => true }, { :default => true }, { :override => true }, { :automatic => true }) + na = Chef::Node::Attribute.new({ normal: true }, { default: true }, { override: true }, { automatic: true }) expect(na.send(accessor)).to eq({ accessor.to_s => true }) end end diff --git a/spec/unit/node/vivid_mash_spec.rb b/spec/unit/node/vivid_mash_spec.rb index 4898c22380..e1021ba0c0 100644 --- a/spec/unit/node/vivid_mash_spec.rb +++ b/spec/unit/node/vivid_mash_spec.rb @@ -61,7 +61,7 @@ describe Chef::Node::VividMash do it "deep converts values through arrays" do expect(root).to receive(:reset_cache).with("foo") - vivid["foo"] = [ { :bar => true } ] + vivid["foo"] = [ { bar: true } ] expect(vivid["foo"].class).to eql(Chef::Node::AttrArray) expect(vivid["foo"][0].class).to eql(Chef::Node::VividMash) expect(vivid["foo"][0]["bar"]).to be true @@ -69,7 +69,7 @@ describe Chef::Node::VividMash do it "deep converts values through nested arrays" do expect(root).to receive(:reset_cache).with("foo") - vivid["foo"] = [ [ { :bar => true } ] ] + vivid["foo"] = [ [ { bar: true } ] ] expect(vivid["foo"].class).to eql(Chef::Node::AttrArray) expect(vivid["foo"][0].class).to eql(Chef::Node::AttrArray) expect(vivid["foo"][0][0].class).to eql(Chef::Node::VividMash) @@ -78,7 +78,7 @@ describe Chef::Node::VividMash do it "deep converts values through hashes" do expect(root).to receive(:reset_cache).with("foo") - vivid["foo"] = { baz: { :bar => true } } + vivid["foo"] = { baz: { bar: true } } expect(vivid["foo"]).to be_an_instance_of(Chef::Node::VividMash) expect(vivid["foo"]["baz"]).to be_an_instance_of(Chef::Node::VividMash) expect(vivid["foo"]["baz"]["bar"]).to be true |