diff options
author | Jay Mundrawala <jdmundrawala@gmail.com> | 2015-03-14 15:15:10 -0700 |
---|---|---|
committer | Jay Mundrawala <jdmundrawala@gmail.com> | 2015-03-20 14:38:05 -0700 |
commit | 34b0725c7328aad2d0542fc95bb12e352101ae94 (patch) | |
tree | c2bd88e65406acd4f370a9cca496da36d76da8ea | |
parent | 6d138c89f63b8b7f7b76987cc2c91ca63438e6e5 (diff) | |
download | chef-34b0725c7328aad2d0542fc95bb12e352101ae94.tar.gz |
Better error message in define_resource_requirements
-rw-r--r-- | lib/chef/provider/dsc_resource.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/provider/dsc_resource.rb b/lib/chef/provider/dsc_resource.rb index 4c9d866222..1e20030229 100644 --- a/lib/chef/provider/dsc_resource.rb +++ b/lib/chef/provider/dsc_resource.rb @@ -54,10 +54,10 @@ class Chef def define_resource_requirements requirements.assert(:run) do |a| a.assertion { supports_dsc_invoke_resource? } - err = "Assuming a previous resource installs Powershell 5.0.10018.0 or higher." + err = ["You must have Powershell version >= 5.0.10018.0 to use dsc_resource."] a.failure_message Chef::Exceptions::NoProviderAvailable, err - a.whyrun err + a.whyrun err + ["Assuming a previous resource installs Powershell 5.0.10018.0 or higher."] a.block_action! end requirements.assert(:run) do |a| |