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
Michael Cheng
March 09, 2017
Programming
1
170
How Much Should We Test?
Presented at SP Tech Talk
Michael Cheng
March 09, 2017
Tweet
Share
More Decks by Michael Cheng
See All by Michael Cheng
Intro to GraphQL Workshop
miccheng
0
89
Prioritizing Technical Debt
miccheng
0
130
JuniorDevSG - Intro to Coding Dojo
miccheng
0
120
Intro to Web Development with PHP - Lesson 1
miccheng
0
110
Engineers.SG Volunteers Training (4 Aug 2018)
miccheng
0
78
Introduction to PHPConf.Asia 2018
miccheng
0
680
What about Ruby on Rails?... from a PHP Guy
miccheng
0
120
Engineers.SG Volunteers Training (July 2017)
miccheng
0
84
Concourse CI in the Wild
miccheng
0
210
Other Decks in Programming
See All in Programming
AWS Organizations で実現する、 マルチ AWS アカウントのルートユーザー管理からの脱却
atpons
0
150
CI改善もDatadogとともに
taumu
0
120
法律の脱レガシーに学ぶフロントエンド刷新
oguemon
5
740
AIの力でお手軽Chrome拡張機能作り
taiseiue
0
170
PHP ステートレス VS ステートフル 状態管理と並行性 / php-stateless-stateful
ytake
0
100
コミュニティ駆動 AWS CDK ライブラリ「Open Constructs Library」 / community-cdk-library
gotok365
2
140
Amazon Bedrock Multi Agentsを試してきた
tm2
1
290
負債になりにくいCSSをデザイナとつくるには?
fsubal
10
2.4k
ペアーズでの、Langfuseを中心とした評価ドリブンなリリースサイクルのご紹介
fukubaka0825
2
330
『品質』という言葉が嫌いな理由
korimu
0
160
Honoとフロントエンドの 型安全性について
yodaka
7
1.3k
Introduction to kotlinx.rpc
arawn
0
700
Featured
See All Featured
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
356
29k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
21
2.5k
Designing on Purpose - Digital PM Summit 2013
jponch
117
7.1k
Done Done
chrislema
182
16k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
27
1.6k
How to Ace a Technical Interview
jacobian
276
23k
Being A Developer After 40
akosma
89
590k
Large-scale JavaScript Application Architecture
addyosmani
511
110k
For a Future-Friendly Web
brad_frost
176
9.5k
KATA
mclloyd
29
14k
How STYLIGHT went responsive
nonsquared
98
5.4k
RailsConf 2023
tenderlove
29
1k
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