Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Test driven development book [closed]

Tags:

tdd

testing

What book would you recommend to learn test driven development? Preferrably language agnostic.

like image 867
Jakub Arnold Avatar asked Apr 28 '09 09:04

Jakub Arnold


People also ask

Is Test Driven Development still used?

TDD is not dead in 2022. It will never be dead because there will always be projects where developers can use TDD effectively. Today and in the future, developers will want to make sure their code is not broken and works properly. By writing tests first, developers can see if they are on the right track or not.

How is BDD different from TDD?

TDD is a development practice while BDD is a team methodology. In TDD, the developers write the tests while in BDD the automated specifications are created by users or testers (with developers wiring them to the code under test.) For small, co-located, developer-centric teams, TDD and BDD are effectively the same.


2 Answers

  • Test Driven Development By Example
  • Refactoring: Improving the Design of Existing Code
  • Extreme Programming: Embrace The Change
like image 79
dfa Avatar answered Sep 17 '22 15:09

dfa


Growing Object-Oriented Software, Guided by Tests by Addison-Wesley - it is about mocking frameworks - JMock and Hamcrest in particular.

From description of the book:

Steve Freeman and Nat Pryce describe the processes they use, the design principles they strive to achieve, and some of the tools that help them get the job done. Through an extended worked example, you’ll learn how TDD works at multiple levels, using tests to drive the features and the object-oriented structure of the code, and using Mock Objects to discover and then describe relationships between objects. Along the way, the book systematically addresses challenges that development teams encounter with TDD--from integrating TDD into your processes to testing your most difficult features.

EDIT: I'm now reading Working Effectively with Legacy Code by Michael Feathers which is pretty good. From the description of the book:

  • Understanding the mechanics of software change: adding features,
    fixing bugs, improving design, optimizing performance
  • Getting legacy code into a test harness
  • Writing tests that protect you against introducing new problems
  • This book also includes a catalog of twenty-four dependency-breaking techniques that help you work with program elements in isolation and make safer changes.

I read it already, it is one of the best programming books I've ever read (I personally think that it must be called Refactoring to Testability - it describes the processes for making your code testable). Because a testable code is good code.

like image 28
Kiril Kirilov Avatar answered Sep 19 '22 15:09

Kiril Kirilov