You are previewing Test-Driven JavaScript Development.

Test-Driven JavaScript Development

Cover of Test-Driven JavaScript Development by Christian Johansen Published by Addison-Wesley Professional
O'Reilly logo

Chapter 2. The Test-Driven Development Process

In Chapter 1, Automated Testing, we were introduced to the unit test, and learned how it can help reduce the number of defects, catch regressions, and increase developer productivity by reducing the need to manually test and tinker with code. In this chapter we are going to turn our focus from testing to specification as we delve into test-driven development. Test-driven development (TDD) is a programming technique that moves unit tests to the front row, making them the primary entry point to production code. In test-driven development tests are written as specification before writing production code. This practice has a host of benefits, including better testability, cleaner interfaces, and improved ...

The best content for your career. Discover unlimited learning on demand for around $1/day.