Testing Chef cookbooks and infrastructure development is a hot topic these days. One of the keynote talks at ChefConf was Test-driven Development for Chef Practitioners. There’s even a book on the topic of Test Driven Infrastructure with Chef. Last month, we shared a guest blog post from Andrew Crump on testing infrastructure, and performing test-driven/behavior-driven development of Chef cookbooks.
This week, we released a new RubyGem, test-kitchen, written by Andrew and our own Seth Chisamore. Test Kitchen provisions an isolated test environment using Vagrant to run project tests on different platforms.
test-kitchen, we have also released our Vagrant base boxes, which we build with another new project called Bento. Bento is a set of Veewee definitions based on Tim Dysinger’s modular DRY basebox.
The test-kitchen documentation, including how to get started is currently in the source tree README.
If you’d like to see example projects that use test-kitchen, we have examples in our apache2 and mysql cookbooks, and the mixlib-shellout RubyGem.
The Bento documentation is in the source tree README. Simply clone the repository and follow the instructions to build your own base boxes. Or, you can use the ones we provide, linked in the README.