Book Image

Test-Driven Java Development

Book Image

Test-Driven Java Development

Overview of this book

Table of Contents (17 chapters)
Test-Driven Java Development
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
8
Refactoring Legacy Code – Making it Young Again
Index

Summary


In this chapter, we briefly talked about software design and a few basic design principles. We implemented a fully-functional version of the board game Connect4 using two approaches: traditional and test-driven development.

We analyzed both solutions in terms of pros and cons, and used a Hamcrest framework to empower our tests.

Finally, we concluded that good design and good practices can be performed by both approaches, but TDD leads developers to the better way.

For further information about the topics that this chapter covers, refer to two highly recommended books written by Robert C. Martin: Clean Code: A Handbook of Agile Software Craftsmanship and Agile Software Development: Principles, Patterns, and Practices.