What Are Golden Tests and When to Use Them (Automated Testing 101)

Max Zimmermann đź’ˇ
7 min readApr 23, 2023

Introduction

One of the challenges of app development is ensuring that your UI’s appearance is consistent across different devices (and platforms) and that no changes happen to a widget or screen when you work on another part of the app. This is where golden testing comes in. Golden testing is a technique that involves comparing the current appearance of a UI component to a “golden” reference image that represents the expected appearance. In this article, we’ll look closer at golden testing for mobile app development, its advantages, disadvantages, and when to use it.

If you want to see how to implement golden testing check out my article Flutter golden testing with the alchemist package.

Table of contents

What is golden testing?

Golden testing is a technique used in software testing to verify that the output of a piece of the software remains unchanged over time. In a golden test, a…

--

--

Max Zimmermann đź’ˇ

Flutter developer. I am excited about learning new things and sharing them with others. https://linktr.ee/maxmitz