DEV Community

Discussion on: The TDD Test

Collapse
 
erikpischel profile image
Erik Pischel

So you mean "delete the TDD test but make sure to write an integration test that covers this code"

Or maybe delete the TDD unit test in the moment it's in the way of refactoring the code because the integration tests gets you covered. Until that, the TDD unit test serves as regression test and (hopefully) kind of documentation.

Collapse
 
eljayadobe profile image
Eljay-Adobe

No, I mean "delete the unit test, because it has served its purpose, and now it is waste" as a way to help educate the developers not to write their unit tests in arrears.

Unit tests written in arrears — if written at all — have poor coverage characteristics, and do not guide design (hence are not TDD).

Integration tests are not a substitute for unit tests.