diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2016-01-12 08:22:09 -0800 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2016-01-12 08:22:09 -0800 |
commit | c844e1c87374b18ee634a06a5325518631607c90 (patch) | |
tree | 59526dce9d78c30e40282e595d914cf703858663 /spec/unit/provider | |
parent | 0944320b72ee1ab16a18a149f5ecb743ace0c0d3 (diff) | |
download | chef-c844e1c87374b18ee634a06a5325518631607c90.tar.gz |
chefstyle: fix Lint/StringConversionInInterpolation
useless use of `"#{foo.to_s}"`
Diffstat (limited to 'spec/unit/provider')
-rw-r--r-- | spec/unit/provider/group/groupadd_spec.rb | 4 | ||||
-rw-r--r-- | spec/unit/provider/group/usermod_spec.rb | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/spec/unit/provider/group/groupadd_spec.rb b/spec/unit/provider/group/groupadd_spec.rb index 94150b7a88..47021a9af3 100644 --- a/spec/unit/provider/group/groupadd_spec.rb +++ b/spec/unit/provider/group/groupadd_spec.rb @@ -42,7 +42,7 @@ describe Chef::Provider::Group::Groupadd, "set_options" do } field_list.each do |attribute, option| - it "should check for differences in #{attribute.to_s} between the current and new resources" do + it "should check for differences in #{attribute} between the current and new resources" do expect(@new_resource).to receive(attribute) expect(@current_resource).to receive(attribute) @provider.set_options @@ -145,7 +145,7 @@ describe Chef::Provider::Group::Groupadd do [:add_member, :remove_member, :set_members].each do |m| it "should raise an error when calling #{m}" do - expect { @provider.send(m, [ ]) }.to raise_error(Chef::Exceptions::Group, "you must override #{m} in #{@provider.to_s}") + expect { @provider.send(m, [ ]) }.to raise_error(Chef::Exceptions::Group, "you must override #{m} in #{@provider}") end end diff --git a/spec/unit/provider/group/usermod_spec.rb b/spec/unit/provider/group/usermod_spec.rb index 3f06e9ebf1..a11d790d07 100644 --- a/spec/unit/provider/group/usermod_spec.rb +++ b/spec/unit/provider/group/usermod_spec.rb @@ -65,7 +65,7 @@ describe Chef::Provider::Group::Usermod do @provider.load_current_resource @provider.instance_variable_set("@group_exists", true) @provider.action = :modify - expect { @provider.run_action(@provider.process_resource_requirements) }.to raise_error(Chef::Exceptions::Group, "setting group members directly is not supported by #{@provider.to_s}, must set append true in group") + expect { @provider.run_action(@provider.process_resource_requirements) }.to raise_error(Chef::Exceptions::Group, "setting group members directly is not supported by #{@provider}, must set append true in group") end it "should raise an error when excluded_members are set" do @@ -75,7 +75,7 @@ describe Chef::Provider::Group::Usermod do @provider.action = :modify allow(@new_resource).to receive(:append).and_return(true) allow(@new_resource).to receive(:excluded_members).and_return(["someone"]) - expect { @provider.run_action(@provider.process_resource_requirements) }.to raise_error(Chef::Exceptions::Group, "excluded_members is not supported by #{@provider.to_s}") + expect { @provider.run_action(@provider.process_resource_requirements) }.to raise_error(Chef::Exceptions::Group, "excluded_members is not supported by #{@provider}") end platforms.each do |platform, flags| |