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
How Much Should We Test?
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Michael Cheng
March 09, 2017
Programming
220
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
How Much Should We Test?
Presented at SP Tech Talk
Michael Cheng
March 09, 2017
More Decks by Michael Cheng
See All by Michael Cheng
Intro to GraphQL Workshop
miccheng
0
160
Prioritizing Technical Debt
miccheng
0
200
JuniorDevSG - Intro to Coding Dojo
miccheng
0
190
Intro to Web Development with PHP - Lesson 1
miccheng
0
160
Engineers.SG Volunteers Training (4 Aug 2018)
miccheng
0
110
Introduction to PHPConf.Asia 2018
miccheng
0
790
What about Ruby on Rails?... from a PHP Guy
miccheng
0
170
Engineers.SG Volunteers Training (July 2017)
miccheng
0
130
Concourse CI in the Wild
miccheng
0
270
Other Decks in Programming
See All in Programming
キャリア迷子上等 ─ "ない道"は自分で作ればいい
16bitidol
3
1.1k
軽量Java基盤の設計 DIコンテナに頼らない、長期保守と1秒起動の実現 JJUG CCC 2026 Spring
macha64
0
450
tsserverとは何だったのか、これからどうなるのか
nowaki28
1
450
LLM Plugin for Node-REDの利用方法と開発について
404background
0
160
Swiftのレキシカルスコープ管理
kntkymt
0
210
TypeSpec で繋ぐ複数プロダクトの型安全
maroon8021
1
380
IBM Bobを活用したレガシーアプリの最新化
oniak3ibm
PRO
1
170
AI駆動開発勉強会 広島支部 第一回勉強会 AI駆動開発概要とワークショップ
hayatoshimiu
0
440
AIとASP.NET Coreで雑Webアプリを作った話
mayuki
0
320
ADKを使って簡単にAIエージェントを作ってみよう
k1mu21
0
230
「エンジニアインターン、どうやって取った?」準備のリアルを語るLT会 Progate BAR
akiomatic
0
120
代数的データ型って何が嬉しいの? #frontend_phpcon_do
kajitack
8
3.2k
Featured
See All Featured
Highjacked: Video Game Concept Design
rkendrick25
PRO
1
380
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
1
770
Gemini Prompt Engineering: Practical Techniques for Tangible AI Outcomes
mfonobong
2
420
How to Ace a Technical Interview
jacobian
281
24k
Faster Mobile Websites
deanohume
310
31k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.7k
Crafting Experiences
bethany
1
170
KATA
mclloyd
PRO
35
15k
A Modern Web Designer's Workflow
chriscoyier
698
190k
Leveraging Curiosity to Care for An Aging Population
cassininazir
1
260
Redefining SEO in the New Era of Traffic Generation
szymonslowik
1
320
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
220
Transcript
HOW MUCH SHOULD WE TEST? Or how to stop hating
your tests
GOALS OF TEST SUITE • Tests should be thorough •
Tests should be stable • Tests should be fast • Tests should be few (minimal)
TEST DRIVEN DEVELOPMENT • We use test cases to guide
the design of our code • 2 approaches to testing - Inside Out and Outside In • Outside In - Use integration tests to guide you • Inside Out - Build & test individual components, integrate later
None
None
Object under test
Object under test Incoming Messages
Object under test Incoming Messages Outgoing Messages
Object under test Incoming Messages Outgoing Messages
Object under test Incoming Messages Outgoing Messages Send to self
Object under test Incoming Messages Outgoing Messages Send to self
Message Types:
Object under test Incoming Messages Outgoing Messages Send to self
Query Message Types:
Object under test Incoming Messages Outgoing Messages Send to self
Command Query Message Types:
MESSAGE TYPES • Query: Returns something / changes nothing •
Command: Returns nothing / changes something Object under test Incoming Messages Outgoing Messages Send to self Command Query
None
None
None
None
None
None
RESOURCES • “The Magic Tricks of Testing” - Sandi Metz
http://confreaks.tv/videos/railsconf2013- the-magic-tricks-of-testing • “Working Effectively with Unit Tests” - Jay Fields https://leanpub.com/wewut