This chapter will cover the following topics:
- A brief overview of test-driven development
- Common myths and questions around TDD
- Whether it takes more efforts for a developer to write unit tests
- Whether code coverage metrics is good or bad
- Whether TDD would work for complex legacy projects
- Whether TDD is even applicable for embedded products or products that involve hardware
- Unit test frameworks for C++
- Google test framework
- Installing Google test framework on Ubuntu
- The process to build a Google test and mock together as one single static library without installing them
- Writing our first test case using Google test framework
- Using Google test framework in Visual Studio IDE
- TDD in action
- Testing legacy code that has dependency
Let's deep dive into these TDD topics.