diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2019-07-03 13:11:13 -0700 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2019-07-05 12:41:04 -0700 |
commit | 9802d7c075c8b7dae42dbcecd92d492f7fa128ac (patch) | |
tree | 0d13de92dc631081f9bcdaddedd6294051e3423b /spec/functional | |
parent | 4978a9a8a402477f3b35f43404701d6a5cf26fa1 (diff) | |
download | chef-9802d7c075c8b7dae42dbcecd92d492f7fa128ac.tar.gz |
Style/NegatedIf
Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Diffstat (limited to 'spec/functional')
-rw-r--r-- | spec/functional/resource/group_spec.rb | 4 | ||||
-rw-r--r-- | spec/functional/run_lock_spec.rb | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/spec/functional/resource/group_spec.rb b/spec/functional/resource/group_spec.rb index 343e4f2f4e..f5bb458666 100644 --- a/spec/functional/resource/group_spec.rb +++ b/spec/functional/resource/group_spec.rb @@ -96,7 +96,7 @@ describe Chef::Resource::Group, :requires_root_or_running_windows do end def create_user(username, uid = nil) - if ! windows_domain_user?(username) + unless windows_domain_user?(username) user_to_create = user(username) user_to_create.uid(uid) if uid user_to_create.run_action(:create) @@ -105,7 +105,7 @@ describe Chef::Resource::Group, :requires_root_or_running_windows do end def remove_user(username) - if ! windows_domain_user?(username) + unless windows_domain_user?(username) u = user(username) u.manage_home false # jekins hosts throw mail spool file not owned by user if we use manage_home true u.run_action(:remove) diff --git a/spec/functional/run_lock_spec.rb b/spec/functional/run_lock_spec.rb index 825f2810d4..d9a8bd2d0e 100644 --- a/spec/functional/run_lock_spec.rb +++ b/spec/functional/run_lock_spec.rb @@ -347,7 +347,7 @@ describe Chef::RunLock do example.log_event("#{name}.run_to(#{to_event.inspect})") # Start the process if it's not started - start if !pid + start unless pid # Tell the process what to stop at (also means it can go) write_to_process.print "#{to_event}\n" @@ -371,7 +371,7 @@ describe Chef::RunLock do def run_to_completion example.log_event("#{name}.run_to_completion") # Start the process if it's not started - start if !pid + start unless pid # Tell the process to stop at nothing (no blocking) @write_to_process.print "nothing\n" |