Skip to content

chaitu6022/test_driven_cookbook_development

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Test Driven Cookbook Development

This is a repository for developing Test Driven Cookbook Development.

Abstract / Description

Test Driven Cookbook Development is a comprehensive instructor-led course exploring Test-driven development (TDD) through explanation, demonstration, practice, and discussion.

Building cookbooks with tests will increase the speed at which you work by giving you consistent feedback throughout the entire cookbook development process.

Participants will learn how to confidently create and extend a cookbook using ChefSpec and ServerSpec. At the end of the course, learners will have created a code repository that can reviewed and applied to solve real business problems.

Webinar Description

Building cookbooks with tests will increase the speed at which you work by giving you consistent feedback throughout the entire cookbook development process. The Chef Development Kit (ChefDK) includes tools that allow you perform both unit testing and integration testing.

In this webinar the facilitator will explain what is unit testing and integration testing, how they apply to the domain of cookbook development, and demonstrate building cookbooks with a test-driven approach. When we're done, you'll know when to apply these two tools, how to use these tools effectively, and know where to continue to build these skills.

Learner Requirements

Participants need a network-enabled laptop with a terminal that supports SSH.

It’s best that learners have some familiarity and comfort with the following:

  • Chef Essentials or Chef Fundamentals or equivalent experience.

Agenda

  • Introduction
  • Why Write Tests? Why is that Hard?
  • Writing a Test First
  • Refactoring Cookbooks with Tests
  • Faster Feedback with Unit Testing
  • Testing Resources in Recipes
  • Refactoring to Attributes
  • Refactoring to Multiple Platforms

Published Content

The latest published version of these training materials are located as follows:

Participant Guide

The participant guide is a PDF that contains the notes export from the content slides.

This content can be found here: CONTENT IS CURRENTLY IN DEVELOPMENT

Instructor Kit

  • All slides for each module

  • Instructor Guide for you to learn from, practice with, and perhaps use as reference while teaching. The instructor guide contains the notes export from the content slides with additional instructor notes and lab setup instructions.

  • Participant Guide

This content can be found here: CONTENT IS CURRENTLY IN DEVELOPMENT

Screencast Videos

This content can be found here: CONTENT IS CURRENTLY IN DEVELOPMENT

Publishing Process

Video on how to export the content from slides to guides: https://drive.google.com/file/d/0B4WmSTt8VtdKZDY5RnhIWVVYZkk/view?usp=sharing

Known Issues

There are no known issues at this time.

Workstation Setup

These modules focus on getting learners engaged with the content as quickly as possible. A workstation is provided to the learners.

Amazon Machine Instance

This workstation is currently being managed as a Amazon Machine Instance (AMI). This AMI is managed by Chef through the Training AWS Account.

  • TDD Cookbook Development - CentOS 6.7 - 1.0.0 (ami-6c6a4706)

The AMI was generated with Packer and adheres to the following policy. It is based on a Marketplace AMI so it cannot be made public. If you would like access to this AMI to deliver training please contact [email protected] the request that includes your Amazon Account Id.

Creating the Workstation

An chef recipe that automates the creation of the workstation can be found in the ChefDK Image project

  • Installation of ChefDK

  • Create a user named 'chef' with the password 'chef'

  • Ensure the yum package repository is up-to-date

$ yum update -y
  • INSTALL various editors and tools that the participant will install: vim; emacs; nano; tree; and git.

  • Install Docker on CentOS

  • Allow Password Authentication

  • Disable the iptables service

  • Disable SELINUX

  • Added an ec2 json hints file (content: {}) to /etc/chef/ohai/hints/ec2.json

About

Learn to write tests and refactor an existing body of cookbooks

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published