puppet-logstash icon indicating copy to clipboard operation
puppet-logstash copied to clipboard

variables enclosed in {}, proper fact scoping, remove quoting for variab...

Open jlambert121 opened this issue 12 years ago • 4 comments

...les only

jlambert121 avatar Feb 18 '13 17:02 jlambert121

I'm trying to get travis-ci setup to do some sensible rspec tests on this module, then I'll let it inspect your pull requests (just as an exercise), then I'll pull this request. Thanks!

simonmcc avatar Feb 20 '13 10:02 simonmcc

I started writing spec tests for this, but the structure of the module (the way dependencies are done) makes it very difficult to write spec tests for. Have you considered refactoring this first?

jlambert121 avatar Feb 26 '13 02:02 jlambert121

Yeah, that's been one of my issues, that and I'm pretty unfamiliar with rspec & rspec-puppet, did you have any suggestions for refactoring it?

(my current role is in a Chef environment, so getting time to further my puppet skills is a bit of a challenge)

On 26 February 2013 02:16, Justin Lambert [email protected] wrote:

I started writing spec tests for this, but the structure of the module (the way dependencies are done) makes it very difficult to write spec tests for. Have you considered refactoring this first?

— Reply to this email directly or view it on GitHubhttps://github.com/simonmcc/puppet-logstash/pull/9#issuecomment-14088792 .

Simon McCartney E: [email protected] M: +44 7710 836 915

simonmcc avatar Feb 26 '13 10:02 simonmcc

The biggest issue I ran into with tests was the way the config class was included and used. I started refactoring, I'm sure there's lots of issues and it would take a lot of testing afterword since there currently isn't any tests.

It may be worth making a new major release and doing a major refactor. I pushed my non-working branch here: https://github.com/jlambert121/simonmcc-logstash/tree/class_refactor. Thoughts?

jlambert121 avatar Feb 27 '13 02:02 jlambert121