From 1cdf154708f682052195db0266f54f7c088c41bb Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Tue, 15 Aug 2023 22:53:23 +0100 Subject: [PATCH] daily-email: add 2023-08-15 Writing test and implementation code are the same task --- src/content/daily-email/2023-08-15.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 src/content/daily-email/2023-08-15.md diff --git a/src/content/daily-email/2023-08-15.md b/src/content/daily-email/2023-08-15.md new file mode 100644 index 00000000..29fb7940 --- /dev/null +++ b/src/content/daily-email/2023-08-15.md @@ -0,0 +1,24 @@ +--- +title: > + Writing test and implementation code are the same task +pubDate: 2023-08-15 +permalink: > + archive/2023/08/15/writing-test-and-implementation-code-are-the-same-task +tags: + - automated-testing + - test-driven-development +--- + +In Sunday's email, I said not to estimate separately for testing and implementation. + +But you can't do this anyway if you're doing test-driven development. + +With TDD, you aren't writing all of your tests and all of the implementation code or vice versa. + +You're continuously switching back and forth, starting by writing a failing test and then enough implementation code for it to pass. + +Then you write more test code, whether expanding the same test or writing a new one until you have a new failure. + +You get it to pass, refactor, and repeat the process until the task is complete. + +It's all part of the same task and the same estimate.