On Dec 13, 2011, at 9:32 PM, Bill Christian <bill.christ...@gmail.com> wrote:
> I have a project that collects various application configurations across a > couple thousand servers and wants to validate settings are following > recommended values. For example, all weblogic servers should have a minimum > memory heap size of 512M. Any violators should be reported. > > Being very impressed with the RSpec DSL, I am using RSpec to validate these > data rules. I pre-populate an object with all configurations for a given > server and use RSpec expectations to ensure they match the recommended > values. My current runner loads each instance and runs RSpec. > > Of course this is not truly performing unit testing, but it appears to be an > easy way to expressively define data rules and run expectations. I've gotten > it to work. However, this is my first time at instrumenting RSpec outside of > rake and creating my own custom formatter. I am curious if I am mangling the > use of RSpec and/or complete missing a better way of scripting RSpec to > perform data validation rules. > > I would really appreciate any feedback on how I am using RSpec, or the runner > code I put together, or suggestions on looking at other projects automating > RSpec executions for inspiration. > > Thanks in advance. > _______________________________________________ > rspec-users mailing list > rspec-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users I can't comment on the specifics of your configuration but I think this is a fine use of RSpec. I love using RSpec for stuff like this. Unit tests aren't the only things in the world that need automated checks :) Pat
_______________________________________________ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users