Skip to content

Test-driven Development

Definition

Test-Driven Development is a software development methodology where the creation of tests precedes the implementation of code. The process begins with the formulation of small, specific test cases that encapsulate the expected behavior of a particular piece of functionality. These tests are initially designed to fail since the corresponding code hasn't been written yet. Developers then proceed to write the minimum amount of code necessary to make the tests pass. Once the tests are successfully passing, the code can be refactored and optimized with confidence, knowing that any regressions will be caught by the existing tests. This methodology promotes incremental development, and ensures that each component is thoroughly tested resulting in more robust and maintainable code.

Relevance

The Test-Driven Development methodology is used for the technical implementation of all the software components that are within the scope of the EDDIE project.

Motivation

Test-Driven Development is the selected methodology for the software implementation because it lead to robust, maintainable, and reusable code while also aiding in identifying and addressing potential issues early in the development cycle.

An alternative to Test-driven development is:

  • Waterfall Model: A more traditional, linear approach where each phase of the development (requirements, design, implementation, testing, maintenance) is completed before moving on to the next.