diff options
author | Tor Magnus Rakvåg <tm@intility.no> | 2018-02-12 14:59:37 +0100 |
---|---|---|
committer | Tor Magnus Rakvåg <tm@intility.no> | 2018-02-12 14:59:37 +0100 |
commit | 79a720927132a695ba8f63f351a2fa6e72df15c0 (patch) | |
tree | c3846fec53a33f245053bf946a716c0d6e15cefe | |
parent | 67fd2daf3151fd3a6eaee90a11aa5792e01e8159 (diff) | |
download | chef-79a720927132a695ba8f63f351a2fa6e72df15c0.tar.gz |
fix chefstyle errors
Signed-off-by: Tor Magnus Rakvåg <tm@intility.no>
-rw-r--r-- | lib/chef/provider/package/powershell.rb | 2 | ||||
-rw-r--r-- | spec/unit/provider/package/powershell_spec.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/provider/package/powershell.rb b/lib/chef/provider/package/powershell.rb index eb65d80e3d..f553aada0a 100644 --- a/lib/chef/provider/package/powershell.rb +++ b/lib/chef/provider/package/powershell.rb @@ -111,7 +111,7 @@ class Chef def build_powershell_command(command, version = nil) command = [command] unless command.is_a?(Array) command.unshift("(") - %w(-Force -ForceBootstrap).each do |arg| + %w{-Force -ForceBootstrap}.each do |arg| command.push(arg) end command.push("-RequiredVersion #{version}") if version diff --git a/spec/unit/provider/package/powershell_spec.rb b/spec/unit/provider/package/powershell_spec.rb index c9fb5b69ca..991de2b26e 100644 --- a/spec/unit/provider/package/powershell_spec.rb +++ b/spec/unit/provider/package/powershell_spec.rb @@ -109,7 +109,7 @@ describe Chef::Provider::Package::Powershell do end it "should use the candidate_version from the correct source" do - allow(provider).to receive(:powershell_out).with("( Find-Package 'xNetworking' -Force -ForceBootstrap -Source MyGallery ).Version", {:timeout => new_resource.timeout }).and_return(package_xnetworking_available) + allow(provider).to receive(:powershell_out).with("( Find-Package 'xNetworking' -Force -ForceBootstrap -Source MyGallery ).Version", { :timeout => new_resource.timeout }).and_return(package_xnetworking_available) new_resource.package_name(["xNetworking"]) new_resource.version(nil) new_resource.source("MyGallery") |