0

I am trying to install .net framework 4.5.2 using puppet module using exec resource instead of using Package resource due to some reason. I want to write a test case to check if it is installed or not. The only way I could find to check if it is installed or not is checking registry key.

I would like to know if I could write a test in rspec-puppet to check if registry exists or not?

HBruijn
  • 77,029
  • 24
  • 135
  • 201
Ankita13
  • 101
  • 1

1 Answers1

0

While I'm not sure about using rspec-puppet for testing if the registry key exists, you can use rspec-puppet to see if the catalogue contains the registry_key resource.

We usually write tests surrounding registry access in rspec - here is an example: https://github.com/puppetlabs/puppetlabs-dsc/blob/master/spec/unit/puppet_x/puppetlabs/dsc_symlink_spec.rb#L122-L152

ferventcoder
  • 347
  • 3
  • 4
  • 12