官术网_书友最值得收藏!

Testing recipes

There are a number of ways to test your recipes. One approach is to simply follow the process of developing your recipes, uploading them to your Chef server, and deploying them to a host; repeat this until you are satisfied. This has the benefit of executing your recipes on real instances, but the drawback is that it is slow, particularly if you are testing on multiple platforms, and requires that you maintain a fleet of hosts. If your cookbook run times are reasonably short and you have a small number of platforms to support them, then this might be a viable option. There is a better option to test your recipes, and it is called ChefSpec. For those who have used RSpec, a Ruby testing library, these examples will be a natural extension of RSpec. If you have never used RSpec, the beginning of this chapter will introduce you to RSpec's testing language and mechanisms.

主站蜘蛛池模板: 涞源县| 芷江| 阿坝| 东阿县| 丰宁| 洪泽县| 安阳市| 吉安县| 儋州市| 宜宾县| 景洪市| 湛江市| 嵩明县| 阿合奇县| 宁阳县| 新密市| 六安市| 沈阳市| 分宜县| 凌海市| 德州市| 塔河县| 晋中市| 武夷山市| 富宁县| 龙海市| 榆社县| 连平县| 义乌市| 尖扎县| 明水县| 台江县| 兴化市| 中宁县| 武汉市| 汤原县| 同德县| 南京市| 临湘市| 富宁县| 宁河县|