How does TDD address interaction between objects?
Posted
by
Gigi
on Programmers
See other posts from Programmers
or by Gigi
Published on 2013-10-02T17:25:44Z
Indexed on
2013/10/21
22:03 UTC
Read the original article
Hit count: 387
unit-testing
|TDD
TDD proponents claim that it results in better design and decoupled objects. I can understand that writing tests first enforces the use of things like dependency injection, resulting in loosely coupled objects. However, TDD is based on unit tests - which test individual methods and not the integration between objects. And yet, TDD expects design to evolve from the tests themselves.
So how can TDD possibly result in a better design at the integration (i.e. inter-object) level when the granularity it addresses is finer than that (individual methods)?
© Programmers or respective owner