Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Cypress vs. Playwright
Search
Matija Marohnić
September 28, 2022
Programming
170
0
Share
Cypress vs. Playwright
Matija Marohnić
September 28, 2022
More Decks by Matija Marohnić
See All by Matija Marohnić
oxlint & oxfmt: linting and formatting from the future
silvenon
0
27
Goodbye jsdom/happy-dom, hello Vitest Browser Mode!
silvenon
0
16
Introduction to Remix
silvenon
0
150
Studying Strapi: an open source head headless CMS
silvenon
0
55
CSS Specificity
silvenon
0
58
Make your JavaScript projects more accessible to newcomers
silvenon
0
87
React Hooks
silvenon
0
91
PostCSS
silvenon
0
60
CSS Custom Properties
silvenon
0
52
Other Decks in Programming
See All in Programming
20260514 - build with ai 2026 - build LINE Bot with Gemini CLI
line_developers_tw
PRO
0
310
How We Benchmarked Quarkus: Patterns and anti-patterns
hollycummins
1
180
JAWS-UG横浜 #100 祝・第100回スペシャルAWS は VPC レスの時代へ
maroon1st
0
220
Surviving Black Friday: 329 billion requests with Falcon!
ioquatix
0
2.9k
AlarmKitで明後日起きれるアラームアプリを作る
trickart
0
110
リセットCSSを1行消したらアクセシビリティが向上した話
pvcresin
4
490
ふにゃっとしない名前の付け方 〜哲学で茹で上げる、コシのあるソフトウェア設計〜
shimomura
0
110
ハーネスエンジニアリングとは?
kinopeee
13
6.8k
属人化しないコード品質の作り方_2026.04.07.pdf
muraaano
0
320
Making the RBS Parser Faster
soutaro
0
670
検索設計から 推論設計への重心移動と Recall-First Retrieval
po3rin
5
1.6k
Symfony AI in Action - SymfonyLive Berlin 2026
chr_hertel
1
120
Featured
See All Featured
AI: The stuff that nobody shows you
jnunemaker
PRO
6
630
Faster Mobile Websites
deanohume
310
31k
Effective software design: The role of men in debugging patriarchy in IT @ Voxxed Days AMS
baasie
0
340
The Cult of Friendly URLs
andyhume
79
6.9k
Embracing the Ebb and Flow
colly
88
5k
Abbi's Birthday
coloredviolet
2
7.5k
Rails Girls Zürich Keynote
gr2m
96
14k
Navigating Weather and Climate Data
rabernat
0
190
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
Docker and Python
trallard
47
3.8k
HDC tutorial
michielstock
2
650
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
130
Transcript
Matija Marohnić Cypress vs. Playwright End-to-end testing showdown https://silvenon.com/blog/e2e-testing-with-cypress-vs-playwright
My experience with Cypress
Background • prior experience with tools like WebdriverIO • used
Cypress for a long time • friendlier API • approachable • but eventually mostly for critical functionality
Speed • 5 tests = 45s (locally) • compared to
my other optimizations it became uncomfortable • started writing less tests 💔
GUI 🤷
GUI
API • familiarity = jQuery 😔 • won’t look familiar
to any new developers
API • should = expect
API • wrap objects to make assertions • another round
of jQuery for everyone! 🍻
API • synchronous…? • commands are queued to be run
later
Meet Playwright 🎭
Background • new testing framework by Microsoft • haven’t used
it in any serious projects yet • only side projects
Supports WebKit • unlike Cypress, Playwright supports Safari • Safari’s
support table can be uncomfortable, so it’s really useful
Headless by default • seemed odd at fi rst •
turned out to be a great feature • less clutter, no dashboards or browsers • run headed only when you need to debug
Speed • 13 tests = 3s ⚡ • more than
2x as many tests = 15x faster • speed is no longer an issue • started testing every square inch of my blog
API • asynchronous, almost everything needs to be awaited
API • at fi rst repetitive and error-prone, mistakes aren’t
always obvious • but gives full control over execution order, more transparent
API • uses Jest’s expect library for assertions, so looks
more like a unit test • doesn’t need a Testing Library plugin, locators are powerful
VS Code extension 🤯 • killer feature • makes Playwright
really e ffi cient to use! • run a test just by clicking on it, and much more • a more balanced approach to GUI — stay in your text editor • 👨💻
…and so much more!
• I’m always excited to learn more about Playwright •
it makes me want to write more tests 🥳