Member-only story
My Innovative Solution to Test Automation: ‘The Simpsons’ Data Reset Pattern
Data reset will greatly reduce a software team’s effort to test data management, and it is particularly useful for automated testing.
This is included in “My Innovative Solution to Test Automation and Continuous Testing” series.

As one of the most iconic TV shows, ‘The Simpsons’ is the longest-running television series in the USA with its first episode aired in 1989. In this article, I would like to explore the mindset of the show’s genius creators that helped to make so many good episodes for over 30 years, and apply it to my software development and test automation.
At the beginning of a typical ‘The Simpsons’ episode:
- Homer is working as a nuclear plant safety technician
- Marge is a housewife
- Bart is a naughty boy at Springfield Elementary School
- Lisa is a smart girl in the same school as her brother
- Maggie is a baby, with a dummy in her mouth most of the time
During the episode, Homer (and his family) might have all sorts of adventures, such as becoming rich, changing jobs, getting injured, becoming a movie star, relocating to a different city, …, etc.
Anyway, it does not matter what has happened during the episode. At the end of the episode, the status will be reset back to its original state, just like what is at the beginning of the episode.
In software testing, test data is always a challenging (but is often neglected initially) problem in test automation. One day I came up with an idea to apply data reset in test automation while watching an episode of “The Simpsons”. Database refreshing is not a new idea, but invoking it for test automation (at the individual test level) was unheard of (at least for me). After many attempts, I managed to implement data reset successfully. Since 2008, I have been invoking database-reset before running automated tests (mostly, before each test case) for a number of web apps. It has become second nature to me in terms of automated testing.