sgnl05 / sgnl05-sssd

Puppet module for SSSD
https://forge.puppet.com/sgnl05/sssd
GNU General Public License v3.0
17 stars 76 forks source link

Warn instead of fail on unsupported systems #73

Closed kyle-williams-1 closed 6 years ago

kyle-williams-1 commented 6 years ago

This module works on some non-supported operating systems. While I understand all OS cannot be support, it would be nice to not have a hard failure. Instead, I've updated the code to warn. This would be very helpful for those aging or even new systems that aren't supported yet.

kyle-williams-1 commented 6 years ago

I may need a some time and/or help getting the tests to expect warning instead of an error.

ghoneycutt commented 6 years ago

Thanks for the contribution!

Try changing the following in spec/classes/init_spec.rb

raise_error(Puppet::Error

to

raise_error(Puppet::Warning

I'm not familiar with using warning() though I bet some permutation of the above should work.

kyle-williams-1 commented 6 years ago

It looks like testing for warnings is a bit more complex. There is some discussion about this and an open issue.

https://github.com/rodjek/rspec-puppet/issues/108 https://github.com/rodjek/rspec-puppet/issues/310

I'm going to work on an alternative that doesn't test warnings. (possibly just removing the tests all together)

kyle-williams-1 commented 6 years ago

I'm not sure if I did this right. I'm very new to rspec.

ghoneycutt commented 6 years ago

@kyle-williams-1 could you please squash your commits and I'll be happy to merge.

kyle-williams-1 commented 6 years ago

@ghoneycutt Thanks. Hopefully that did it!

ghoneycutt commented 6 years ago

Released in v2.9.0