1 of 28

I LOVED

SNAPSHOTS

IN 2016

A Decade Later,

Let's Revisit

2025, 30Oct = 24Dec

ROBIN POKORNY

2 of 28

3 of 28

4 of 28

5 of 28

TONIGHT

01

02

03

WHAT IS

SNAPSHOT

TESTING

WHAT WENT WRONG

WHAT

NOW?

6 of 28

WHAT IS

SNAPSHOT

TESTING

01

7 of 28

8 of 28

9 of 28

10 of 28

11 of 28

12 of 28

13 of 28

14 of 28

WHAT�WENT WRONG

02

15 of 28

16 of 28

17 of 28

‘The most common�drawback is�the fragility�of snapshot tests’

—STIP PAPER

18 of 28

Tests don't encode what's important

LACK OF DEVELOPER INTENTION

Developers don't scrutinize them

GENERATED FILE PROBLEM

Need manual verification

LARGE SNAPSHOTS

Tests fail when code is actually fine

HIGH FALSE NEGATIVES

19 of 28

20 of 28

WHAT

NOW?

03

21 of 28

22 of 28

USE

AVOID

  • API response structures (not UI)
  • Error messages and CLI output for developer-facing tools
  • Code transformations
  • Small, stable components in design systems
  • Legacy refactoring
  • Large component trees
  • Components with frequent changes
  • "It renders" smoke tests (use linting instead)
  • Testing behavior
  • As primary testing strategy

23 of 28

24 of 28

25 of 28

TAKEAWAY

SNAPSHOTS PROVIDE VALUE

WHEN USED EFFECTIVELY

26 of 28

me@robinpokorny.com

Let’s connect

IN/IG/YT

WEB

NAME

27 of 28

STATE OF JS

https://survey.devographics.com/survey/state-of-js/2025

28 of 28