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
Testing Express: 0 to 100 in 30 slides
Search
Tuenti
July 16, 2016
Programming
5
330
Testing Express: 0 to 100 in 30 slides
Tuenti
July 16, 2016
Tweet
Share
More Decks by Tuenti
See All by Tuenti
Creating a culture of learning at Tuenti
tuenti
1
80
Poniendo Kotlin en producción a palos
tuenti
0
79
Culture Matters
tuenti
1
160
Defensive Programming & Resilient systems in Real World (TM)
tuenti
1
1.4k
How .Tuenti develops tech products
tuenti
0
67
Microservices and Testing, talking from the experience
tuenti
2
140
Love your tests
tuenti
0
1.2k
Experiences with Microservices at Tuenti
tuenti
0
210
Tuenti <3 Testing
tuenti
0
1.2k
Other Decks in Programming
See All in Programming
Universal Linksの実装方法と陥りがちな罠
kaitokudou
1
220
飲食業界向けマルチプロダクトを実現させる開発体制とリアルな現状
hiroya0601
1
390
gopls を改造したら開発生産性が高まった
satorunooshie
8
240
What’s New in Compose Multiplatform - A Live Tour (droidcon London 2024)
zsmb
1
330
カラム追加で増えるActiveRecordのメモリサイズ イメージできますか?
asayamakk
4
1.5k
Modern Angular: Renovation for Your Applications
manfredsteyer
PRO
0
200
詳細解説! ArrayListの仕組みと実装
yujisoftware
0
480
Generative AI Use Cases JP (略称:GenU)奮闘記
hideg
0
150
ECS Service Connectのこれまでのアップデートと今後のRoadmapを見てみる
tkikuc
2
210
Vue.js学習の振り返り
hiro_xre
2
130
hotwire_or_react
harunatsujita
8
4k
Why Spring Matters to Jakarta EE - and Vice Versa
ivargrimstad
0
960
Featured
See All Featured
The Cult of Friendly URLs
andyhume
78
6k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
226
22k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
126
18k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9.1k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
364
22k
Fireside Chat
paigeccino
32
3k
The Illustrated Children's Guide to Kubernetes
chrisshort
48
48k
Embracing the Ebb and Flow
colly
84
4.4k
Music & Morning Musume
bryan
46
6.1k
Faster Mobile Websites
deanohume
304
30k
Learning to Love Humans: Emotional Interface Design
aarron
272
40k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
Transcript
Testing Express: 0 to 100 in 30 slides
[email protected]
@kinisoftware
Self-promotion Q&A => http:/ /goo.gl/slides/x4c4xw
Why this talk? • We <3 our customers • Confidence
• Safety Net • Refactoring, refactoring, refactoring • It is professional, guys :) Q&A => http:/ /goo.gl/slides/x4c4xw
By Mike Cohn Q&A => http:/ /goo.gl/slides/x4c4xw
Black-box oriented tests End to end Phone/simulator No tests doubles
can be used Needs a full & provisionable server environment Slow tests Page Objects Q&A => http:/ /goo.gl/slides/x4c4xw
JVM No need external env set up Tests run in
build time Use test doubles Slower tests than unit tests Q&A => http:/ /goo.gl/slides/x4c4xw
JVM Application classes in isolation Test doubles Build time Really
fast tests F.I.R.S.T. Q&A => http:/ /goo.gl/slides/x4c4xw
What’s wrong with this?
Testability • Mixing object graph construction with application logic •
Ask for things, don’t look for things • Doing work in constructor • Global State/Singletons • Static methods Q&A => http:/ /goo.gl/slides/x4c4xw
Test Doubles • Stubs => Canned answers • Mocks =>
Stubs + verify • Spies => Record interaction info • Fake => I seem real but not • Dummy => I do nothing at all Q&A => http:/ /goo.gl/slides/x4c4xw
“It’s overwhelmingly easy to write bad unit tests that add
very little value to a project while inflating the cost of code changes astronomically.” • Code coverage != Test quality • Don’t Repeat Yourself (Globally) • Mocks, mocks everywhere • Test smells
Talk is cheap. Show me the code.
Q&A => http:/ /goo.gl/slides/x4c4xw
None
Q&A => http:/ /goo.gl/slides/x4c4xw
None
Code readability + Naming + Code structure + DSL
None
Q&A => http:/ /goo.gl/slides/x4c4xw
None
• Builders
Builders + Mothers
None
None
None
Q&A => http:/ /goo.gl/slides/x4c4xw
Q&A
[email protected]
@kinisoftware http:/ /goo.gl/slides/x4c4xw
Thanks!! We are hiring!
[email protected]
@kinisoftware
Extra Ball • Mix JVM Languages (Groovy, Scala, Kotlin, etc)
• Java 8 fuck yeah! • JUnit 5 • Mutation Testing
Extra Ball • Effective Unit Testing • WEWUT • Pragmatic
Unit Testing with JUnit • GOOS • The Art of Unit Testing • JUnit in Action • xUnit Patterns • Refactoring