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 to write good tests?
Search
Alexander Beletsky
April 12, 2013
Programming
2
320
How to write good tests?
Small talk that I gave to @debitoor guys about practices of writing tests.
Alexander Beletsky
April 12, 2013
Tweet
Share
More Decks by Alexander Beletsky
See All by Alexander Beletsky
Snapshot Testing: Going beyond UI
alexbeletsky
1
680
Tech Culture in Startups
alexbeletsky
0
230
TDD in JavaScript
alexbeletsky
4
850
This is Node.js
alexbeletsky
10
440
Likeastore
alexbeletsky
3
140
PaaS in your pocker with Dokku
alexbeletsky
7
2.6k
Building Single Page Applications
alexbeletsky
9
5.4k
.NET developer in JavaScript world
alexbeletsky
1
2.9k
Dynamic web development with Oak
alexbeletsky
1
620
Other Decks in Programming
See All in Programming
Basic Architectures
denyspoltorak
0
670
「ブロックテーマでは再現できない」は本当か?
inc2734
0
980
CSC307 Lecture 02
javiergs
PRO
1
780
AIによるイベントストーミング図からのコード生成 / AI-powered code generation from Event Storming diagrams
nrslib
2
1.9k
izumin5210のプロポーザルのネタ探し #tskaigi_msup
izumin5210
1
110
高速開発のためのコード整理術
sutetotanuki
1
400
【卒業研究】会話ログ分析によるユーザーごとの関心に応じた話題提案手法
momok47
0
200
AI時代の認知負荷との向き合い方
optfit
0
160
責任感のあるCloudWatchアラームを設計しよう
akihisaikeda
3
170
MUSUBIXとは
nahisaho
0
130
Package Management Learnings from Homebrew
mikemcquaid
0
220
CSC307 Lecture 04
javiergs
PRO
0
660
Featured
See All Featured
New Earth Scene 8
popppiees
1
1.5k
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
1
54
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
51
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
0
410
Navigating Weather and Climate Data
rabernat
0
100
Become a Pro
speakerdeck
PRO
31
5.8k
Breaking role norms: Why Content Design is so much more than writing copy - Taylor Woolridge
uxyall
0
160
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
508
140k
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
1
440
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
196
71k
16th Malabo Montpellier Forum Presentation
akademiya2063
PRO
0
49
Deep Space Network (abreviated)
tonyrice
0
48
Transcript
How to write good tests?
Honestly, I don’t know
But, there are properties of good tests…
… are written before code
… are running very fast
… are helping to find regressions
Writing unit tests is not about code verification
… it’s about code quality and design
Think different Think TDD
Could TDD be applied to everything?
In short, yes code, requirements, ui
Should TDD be applied to everything?
Probably, no simple tasks, prototypes
There are few techniques of writing tests
Classic school Kent Beck, 90’s Inside-Out design Focusing on logic
(algorithms)
London school Jason Gorman, 00’s Outside-In design Focusing on collaboration
Mocks
What about integration tests?
They are slow, hard to write, hard to setup… but
… they usually caught most nasty bugs.
None
Maintaining test driven cycle
None
Acceptance test (PO communication) API (integration) tests Utils (units) tests
Thanks, @alexbeletsky