[although i've commented on the excellent blog entry, i'm posting here]
Hi Martin,
It looks like there's a bit of crossover here with a project i've been
working on the last few months called cucumber-nagios[0]. It takes the
result of a Cucumber run and outputs it in the Nagios plugin format.
Essentially you use it to express your intentions in plain language,
and verify your intentions periodically through your monitoring
system. Just like what you've posted about. :-)
Anyhow, I spoke about cucumber-nagios at the excellent Devopsdays in
Belgium last weekend, and I got talking with people about expanding
the library of steps to cover things like logins over SSH, file
manipulation, and mail delivery. It would be cool if we could
centralise our efforts and focus on building an awesome library of
reusable steps to test our infrastructure.
Your point about doing behaviour driven development when writing
software is right on the mark. From an infrastructure perspective, I
like to think of Cucumber as the testing tool, and Puppet as the
programming language.
Anyhow, i'd be interested to hear what other people think about this idea!
Cheers,
Lindsay
[0] http://auxesis.github.com/cucumber-nagios
--
http://holmwood.id.au/~lindsay/ (me)
3 projects that I've bookmarked to look at for unit testing frameworks
for the OS are:
https://fedoraproject.org/wiki/AutoQA
http://autotest.kernel.org/
http://www.linux-kvm.org/page/Main_Page
I haven't had time to do much more than scan the web site, but they seem
to be worth watching.
I've also started including test.pp scripts as part of each module.
These scripts check directories or do some execs (i.e. wgets, pings,
lookups). These scripts then run with every puppet update push.
However, this isn't ideal for production and there needs to be a better
way to trigger the running of unit tests. But it has been helpful in
validating iptables configuration and ensuring services and their
clients are on the same network.
I think the whole topic is really hot. :-)
It would probably a good idea to expand what the difference between TDD
and BDD in systems management actually is about.
Not everyone here on the list is fine with the subtle differences in
terminology (for example, me ;-) )
Regards
Christian
--
Dipl.-Inf. Christian Kauhaus <>< · k...@gocept.com · systems administration
gocept gmbh & co. kg · forsterstraße 29 · 06112 halle (saale) · germany
http://gocept.com · tel +49 345 1229889 11 · fax +49 345 1229889 1
Zope and Plone consulting and development
So i've added some SSH steps to cucumber-nagios, along the lines of
what Martin blogged about a few days ago.
I've published a blog post about the new feature, and how this could
potentially be used withina Behaviour Driven Infrastructure
techniques:
http://holmwood.id.au/~lindsay/2009/11/09/behaviour-driven-infrastructure-through-cucumber/
Cheers,
Lindsay
--
http://holmwood.id.au/~lindsay/ (me)
We use Puppet at our site quite extensively and try to start
implementing a feature by writing a custom Nagios check[1]. This starts
as a red one. After that we modify the manifests so that the check
passes. I think this is pretty much a TDD style of development. What
part of the procedure would I need to change in a BDD style of
development? Is this just another representation of the checks? Are
there differences in the process?
Regards
Christian
[1] With the Nagios::Plugin Perl library, this is just a breeze.
I've put my collection of infrastructure testing links online:
http://www.jedi.be/blog/2009/11/12/collection-of-test-driven-infrastructure-links/
Great compilation. Thank you for sharing it with us. :-)
Regards
Christian