The Clean Test Automation Monthly is a monthly blog post that shares interesting or useful test automation content that I consumed during the current month. This blog post is always published on the first day of the "next" month.
Let's begin!
Test Design
Run Fewer Tests, Catch the Same Bugs describes how running the correct tests cuts test execution time without compromising our ability to catch real bugs.
We Finally Got the Tests. Now We Don’t Trust Them explains why AI-generated unit tests can pass even though the application breaks in production and describes how we can solve this problem.
The Test Was Wrong. Rewriting explains why an AI agent might "fix the test" even though the test failure was caused by a bug in the production code.
Flaky Tests: How to Fix the Suite You Stopped Trusting explains how we should address flaky tests before they destroy trust in our automated test suite.
Stop Writing Unit Tests for Coverage. Instead, Ask What Bug the Test Would Catch explains why having no tests is better than having bad tests, identifies the characteristics of a good test, and helps us to write more meaningful tests that catch real bugs.
Half my test suite asserts that nothing happened argues that tests which check that the tested software did nothing are just as important as tests which check that something happened.
AI Doesn’t Test Your Product. It Tests Your PRD. Here’s the Difference argues that AI-generated tests don't test the product. They test the requirements of the product. The author also describes why this is a problem.
Backend
Testing your auto-configuration against a missing optional dependency describes how we can write an automated test which ensures that our library or Spring Boot Starter works when an optional dependency is missing from the user's classpath.
Testing Kafka Consumer Recovery Contracts With Testcontainers and JUnit explains how unit tests can pass while the Kafka consumer is broken in production, and describes how we can write proper tests for Kafka consumer recovery contracts with Testcontainers and JUnit.
UI / End-to-End
Lock the Resource, Not the Suite: Parallel Playwright Tests That Share State explains how we can safely run parallel Playwright tests that share mutable state by locking shared resources.
Reuse Your Playwright Tests for Load Testing argues that we should reuse our existing end-to-end tests for load testing instead of building and maintaining a separate test suite.
Cypress 16: faster tests, starting with HTTP/2 support highlights the new features and performance improvements of Cypress 16.
Parallel Testing in Playwright with TypeScript: A Practical Guide to Workers & Cross-Browser Testing explains how we can configure and optimize the parallel execution of Playwright tests by using worker processes and sharding.