🌻 TDD (Test Driven Development)

GunhoΒ·2025λ…„ 1μ›” 21일

🌻 TDD (Test Driven Development)

🌻 TDD (Test Driven Development) is a software development process where the tests may be written before the production codes.

TDD was introduced following the 'test first' principle from the eXtreme Programming (XP) of the Agile methodology.

TDD involves three cycles in large:

  • πŸ”΄ Red - Write Tests

  • 🟒 Green - Write Code

  • πŸ”΅ Refactor - Refactor Code

where these cycles can be further split into overall 5 steps as described below.

IBM Available here


TDD varies from the conventional life cycle of software development, where the testing may be placed just before the deployment and maintenance stage, the final stage.

Geeks for Geeks Available here


πŸ”­ TDD Analysis


πŸ”² TDD Pros

TDD can be introduced as:

  • πŸ“ compels developers to follow the requirements

    • leading to clean and maintainable codes.

    • lowers the risk of over-engineering.

  • πŸ§„ mitigates the fear of sequential updates or refactoring

  • ⏰ mitigates the debugging time

  • πŸ“” increases the test coverages


πŸ”³ TDD Cons

TDD however:

  • 🎼 incurs an overhead for writing tests

    • leading to lower productivity.

    • may not be suitable for very highly dynamic environments.


πŸ“š References

IBM
Geeks for Geeks

profile
Hello

0개의 λŒ“κΈ€