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
Luis Ascorbe: UI and Snapshottesting
Search
Realm
July 08, 2016
Technology
0
7k
Luis Ascorbe: UI and Snapshottesting
Realm
July 08, 2016
Tweet
Share
More Decks by Realm
See All by Realm
WWDC 2017 Review
realm
0
2.1k
Xcode shortcuts
realm
0
4.7k
Self Branding with GitHub
realm
0
4.3k
Realm Mobile Platform overview and demo
realm
0
2k
Realm advanced topics and demo
realm
0
2k
Realm introduction Seoul meetup 10
realm
0
2.1k
Stuart Hall: How I got 2.3 Million App Downloads
realm
0
1.9k
James Majors: What the Swiftly Func?
realm
1
4.3k
Simina Pasat: Continuous everything for iOS apps
realm
0
620
Other Decks in Technology
See All in Technology
PHPでWebブラウザのレンダリングエンジンを実装する
dip_tech
PRO
0
220
LangSmith×Webhook連携で実現するプロンプトドリブンCI/CD
sergicalsix
1
150
20250625 Snowflake Summit 2025活用事例 レポート / Nowcast Snowflake Summit 2025 Case Study Report
kkuv
1
370
Github Copilot エージェントモードで試してみた
ochtum
0
130
ドメイン特化なCLIPモデルとデータセットの紹介
tattaka
1
390
変化する開発、進化する体系時代に適応するソフトウェアエンジニアの知識と考え方(JaSST'25 Kansai)
mizunori
1
260
Should Our Project Join the CNCF? (Japanese Recap)
whywaita
PRO
0
290
プロダクトエンジニアリング組織への歩み、その現在地 / Our journey to becoming a product engineering organization
hiro_torii
0
140
Understanding_Thread_Tuning_for_Inference_Servers_of_Deep_Models.pdf
lycorptech_jp
PRO
0
150
Core Audio tapを使ったリアルタイム音声処理のお話
yuta0306
0
150
Tech-Verse 2025 Keynote
lycorptech_jp
PRO
0
1.3k
How Community Opened Global Doors
hiroramos4
PRO
1
130
Featured
See All Featured
What’s in a name? Adding method to the madness
productmarketing
PRO
23
3.5k
Gamification - CAS2011
davidbonilla
81
5.3k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
10
940
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
16k
Designing for Performance
lara
609
69k
How GitHub (no longer) Works
holman
314
140k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
48
5.4k
The Art of Programming - Codeland 2020
erikaheidi
54
13k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
29
9.5k
Become a Pro
speakerdeck
PRO
28
5.4k
jQuery: Nuts, Bolts and Bling
dougneiner
63
7.8k
Transcript
Snapshot Testing
@lascorbe
@lascorbe
What’s Testing?
What’s Snapshot Testing? Saved!
What’s Snapshot Testing? Saved! Recreate! ==
Calabash KIF UI Testing (Xcode)
Calabash KIF UI Testing (Xcode) Acceptance Tests
What’s Snapshot Testing? Unit Tests Integration Tests
What’s Snapshot Testing? Integration Tests Snapshot Tests Unit Tests
None
States
Text
Devices
Demo!
FBSnapshotTestCase
FBSnapshotTestCase CGContextRef
FBSnapshotTestCase CGContextRef CGContextRef
FBSnapshotTestCase CGContextRef CGContextRef <>
FBSnapshotTestCase CGContextRef CGContextRef <> memcmp()
Things to take into account
Arquitecture
Arquitecture Asynchronicity
Arquitecture Asynchronicity Autolayout
Arquitecture Asynchronicity Autolayout Repo space
What’s nice
See changes without running your app
Gorgeous PRs!
You’re testing a whole view at once
Gotta go fast! “0.015 to 0.080 seconds per test on
a Macbook Air” - @orta
Bonus point
Snapshots
Snapshots-Peek
Conclusion
Conclusion 1. Open your app 2. Write some snapshot tests
3. … 4. Profit!
https://github.com/facebook/ios-snapshot-test-case https://www.objc.io/issues/15-testing/snapshot-testing/ https://github.com/ashfurrow/Nimble-Snapshots https://github.com/dblock/ios-snapshot-test-case-expecta https://github.com/orta/snapshots https://github.com/orta/snapshots-peek https://github.com/Lascorbe/cmduconf-project
One more thing…
None
Sept 14-16 Logroño nsspain.com
cmduconf-rocks
@lascorbe