summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2018-05-03 15:11:28 -0700
committerTim Smith <tsmith@chef.io>2018-05-03 15:11:28 -0700
commit8a5891b2c144a8eb8460fed74cfd4f2e9291b337 (patch)
tree0e4ace706a08fe0595563d04b89b2339c535362a
parent92e03cdd565adb06f28bbf1a978a2be1d74e1830 (diff)
downloadchef-rubocop_055.tar.gz
Fix two new Chefstyle warnings with Rubocop 0.55rubocop_055
These should have been caught before. Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r--spec/functional/resource/group_spec.rb2
-rw-r--r--spec/unit/provider/powershell_script_spec.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/spec/functional/resource/group_spec.rb b/spec/functional/resource/group_spec.rb
index 03c14382e9..ea9aa5c2b7 100644
--- a/spec/functional/resource/group_spec.rb
+++ b/spec/functional/resource/group_spec.rb
@@ -81,7 +81,7 @@ describe Chef::Resource::Group, :requires_root_or_running_windows, :not_supporte
if user && domain != "."
computer_name = ENV["computername"]
- !domain.casecmp(computer_name.downcase).zero?
+ !domain.casecmp(computer_name.downcase) == 0
end
end
diff --git a/spec/unit/provider/powershell_script_spec.rb b/spec/unit/provider/powershell_script_spec.rb
index d7a1620530..f4663861c6 100644
--- a/spec/unit/provider/powershell_script_spec.rb
+++ b/spec/unit/provider/powershell_script_spec.rb
@@ -84,7 +84,7 @@ describe Chef::Provider::PowershellScript, "action_run" do
provider_flags.find do |value|
execution_policy_index += 1
- execution_policy_specified = value.casecmp("-ExecutionPolicy".downcase).zero?
+ execution_policy_specified = value.casecmp("-ExecutionPolicy".downcase) == 0
end
execution_policy = execution_policy_specified ? provider_flags[execution_policy_index] : nil