From f15b60e5bc0c1cf3c1e38812c2962ac50714ee28 Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Sat, 15 Jul 2023 23:27:19 +0100 Subject: [PATCH] daily-email: add 2023-07-15 Test-Driven Development makes you more productive --- src/content/daily-email/2023-07-15.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 src/content/daily-email/2023-07-15.md diff --git a/src/content/daily-email/2023-07-15.md b/src/content/daily-email/2023-07-15.md new file mode 100644 index 00000000..399a33bd --- /dev/null +++ b/src/content/daily-email/2023-07-15.md @@ -0,0 +1,22 @@ +--- +title: > + Test-driven development makes you more productive +pubDate: 2023-07-15 +permalink: > + archive/2023/07/15/test-driven-development-makes-you-more-productive +tags: + - automated-testing + - test-driven-development +--- + +I think that test-driven development (TDD) makes you productive. + +Firstly, you save time by not needing to switch from your code to a terminal or browser to test it. + +But, just as importantly, TDD reduces procrastination. It's much clearer to see what the next steps are. + +You're either thinking and designing your code when writing a failing test or fixing the test failures in the implementation code to get the test to pass. You can focus on each failure and message separately and get them to pass instead of thinking about the whole feature or the rest of the application. + +Once you have a working test, you can focus on refactoring any code or moving on to writing the next assertion or the next test. + +I think that achieving small tasks with short feedback loops using test-driven development makes it much easier to remain productive and focussed.