uuid: - value: ca4340a2-6371-457a-8e95-885adbcdc256 langcode: - value: en type: - target_id: daily_email target_type: node_type target_uuid: 8bde1f2f-eef9-4f2d-ae9c-96921f8193d7 revision_timestamp: - value: '2025-05-11T09:00:34+00:00' revision_uid: - target_type: user target_uuid: b8966985-d4b2-42a7-a319-2e94ccfbb849 revision_log: { } status: - value: true uid: - target_type: user target_uuid: b8966985-d4b2-42a7-a319-2e94ccfbb849 title: - value: | Writing tests in your own time created: - value: '2023-08-16T00:00:00+00:00' changed: - value: '2025-05-11T09:00:34+00:00' promote: - value: false sticky: - value: false default_langcode: - value: true revision_translation_affected: - value: true path: - alias: /daily/2023/08/16/writing-tests-in-your-own-time langcode: en body: - value: |
This is how I first started writing automated tests.
I was working at a well-known digital agency, so I didn't want it to affect my output and cause me to deliver work late.
I wanted to give myself a less pressured opportunity to learn and experiment with different options and approaches.
So, when creating custom modules, I wrote the implementation code during billable work hours and the tests during the evening on my own time.
I was investing time in learning a new skill and one that I knew would pay dividends.
As I'd already written the implementation code, I wasn't doing test-driven development, so most of the tests were confirming what I'd written was correct with a passing test and being able to make it fail in expected ways.
One time, though, I found a bug I'd written that day. I think it was an incorrect permission name I'd typed.
I was able to fix it before it was submitted for quality assurance checks and client testing.
This saved the time and effort of creating another issue and branch, fixing it, going through the development cycle again and having it re-tested.
After that, for me, there was no going back.
format: full_html processed: |This is how I first started writing automated tests.
I was working at a well-known digital agency, so I didn't want it to affect my output and cause me to deliver work late.
I wanted to give myself a less pressured opportunity to learn and experiment with different options and approaches.
So, when creating custom modules, I wrote the implementation code during billable work hours and the tests during the evening on my own time.
I was investing time in learning a new skill and one that I knew would pay dividends.
As I'd already written the implementation code, I wasn't doing test-driven development, so most of the tests were confirming what I'd written was correct with a passing test and being able to make it fail in expected ways.
One time, though, I found a bug I'd written that day. I think it was an incorrect permission name I'd typed.
I was able to fix it before it was submitted for quality assurance checks and client testing.
This saved the time and effort of creating another issue and branch, fixing it, going through the development cycle again and having it re-tested.
After that, for me, there was no going back.
summary: null field_daily_email_cta: { }