DEV Community

Rafaela Nascimento Carvalho
Rafaela Nascimento Carvalho

Posted on

TDD -> Test Driven Development

It is a development approach, where the objective is to start testing before code.

TDD's timeline

Red

  • Create the test visualizing the final objective. Ex: create a profile, the test must cover the process until the end.
  • At this stage the test must fail.

Green

  • The implementation of the code begins, which must be developed until the test created in the RED stage is stabilized.
  • At this stage the test must be successful.

Refactor

  • The code must be refactored to improve quality and clarity.
  • At this stage the test must be successful. Support material:

https://www.youtube.com/watch?v=NxTgE4rx9uk

https://www.youtube.com/watch?v=bLdEypr2e-8&t=405s

Top comments (0)