sous-chefs / powershell

Development repository for the powershell cookbook
https://supermarket.chef.io/cookbooks/powershell
Apache License 2.0
110 stars 88 forks source link

Provide powershell_version helper #53

Closed bheuvel closed 8 years ago

bheuvel commented 9 years ago

Written a helper function which returns (true/false) if the requested versionlevel is present.

This simplifies the guards, and provides a method for other cookbooks to check if a minimum version is present. E.g. WMF5/Feb versionlevel is required for certain DSC (Chef 12) stuff, while with Chef 11 the WMF5-2014 is already enough.

Perhaps not the most beautiful code (let me know how/where to adjust/improve), but useful nonetheless :wink:

smurawski commented 8 years ago

I love the idea here, but given recent changes to the cookbook it break all sorts of tests. I'll try to resurrect this idea in a little while.

bheuvel commented 8 years ago

Rebased to current master, squashed rubocop commits.

These specific tests work. The other/existing tests are broken...

smurawski commented 8 years ago

Closed via #77