Kitchen provides a test harness to execute infrastructure code on one or more platforms in isolation.
A driver plugin architecture is used to run code on various cloud providers and virtualization technologies such as Amazon EC2, Google GCE, Azure, Blue Box, CloudStack, Digital Ocean, Rackspace, OpenStack, Vagrant, Docker, LXC containers, and more.
Kitchen is used by all Chef-managed community cookbooks and is the integration testing tool of choice for cookbooks.
--- driver: name: vagrant provisioner: name: chef_zero platforms: - name: ubuntu-14.04 - name: windows-2012r2 suites: - name: client run_list: - recipe[postgresql::client] - name: server run_list: - recipe[postgresql::server]
$ kitchen create $ kitchen converge $ kitchen setup $ kitchen verify $ kitchen destroy
There are five basic commands to provision platforms and test infrastructure code.
--> Running rspec test suites ✔ git binary is found in PATH 3 tests, 2 failures Finished verifying <default-ubuntu-1404> (0m0.98s). --> Destroying --> Kitchen is finished. (1m44.11s)