Scrum
PSD · Question #146
While practicing Test-Driven Development, what is done after the test fails? (choose the best answer)
The correct answer is B. Write the minimum amount of product code to satisfy the test. Test-Driven Development (TDD) involves writing a failing test first, then writing the minimal code needed to make the test pass. This iterative process ensures code correctness and encourages
Test Driven Development
Question
While practicing Test-Driven Development, what is done after the test fails? (choose the best answer)
Options
- AMeet with the business analyst to ensure that the test is correct.
- BWrite the minimum amount of product code to satisfy the test.
- CRun it again to make sure it really fails.
- DImplement the required functionality.
- ERefactor the test so the code passes.
How the community answered
(47 responses)- A4% (2)
- B87% (41)
- C6% (3)
- E2% (1)
Explanation
Test-Driven Development (TDD) involves writing a failing test first, then writing the minimal code needed to make the test pass. This iterative process ensures code correctness and encourages
Topics
#TDD cycle#red-green-refactor#failing test#minimum code
Community Discussion
No community discussion yet for this question.