Git with Test-Driven Development
Learn how to use Git with test-driven development.
We'll cover the following...
Checking in changes
Whenever you add a new test and get it to pass, that’s a good time to get your project into source control. That way, no matter what you do to the project, you can always restore it to the all-green state later.
We’ll use Git as our source control system in this course. If you’re not familiar with Git, you might want to read through the “Git Basics” section of the excellent Pro Git by Scott Chacon and Ben Straub.
The first step is initializing this project as a Git repository:
$ git init
Initialized empty Git repository in
/Users/tburnham/code/test-driven-fizzbuzz/.git/
Don’t commit just yet. If you run git status
, you’ll notice that ...