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
290
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
620
Tech Culture in Startups
alexbeletsky
0
190
TDD in JavaScript
alexbeletsky
4
840
This is Node.js
alexbeletsky
10
410
Likeastore
alexbeletsky
3
130
PaaS in your pocker with Dokku
alexbeletsky
7
2.5k
Building Single Page Applications
alexbeletsky
9
5.3k
.NET developer in JavaScript world
alexbeletsky
1
2.7k
Dynamic web development with Oak
alexbeletsky
1
590
Other Decks in Programming
See All in Programming
TCAを用いたAmebaのリアーキテクチャ
dazy
0
240
Boos Performance and Developer Productivity with Jakarta EE 11
ivargrimstad
0
800
Your Architecture as a Crime Scene:Forensic Analysis @bastacon 2025 in Frankfurt
manfredsteyer
PRO
0
130
メンテが命: PHPフレームワークのコンテナ化とアップグレード戦略
shunta27
0
340
CDK開発におけるコーディング規約の運用
yamanashi_ren01
2
270
The Clean ArchitectureがWebフロントエンドでしっくりこないのは何故か / Why The Clean Architecture does not fit with Web Frontend
twada
PRO
62
20k
❄️ NixOS/nixpkgsにSATySFiサポートを実装する
momeemt
1
100
iOSでQRコード生成奮闘記
ktcryomm
2
140
DevNexus - Create AI Infused Java Apps with LangChain4j
kdubois
0
150
Domain-Driven Design (Tutorial)
hschwentner
13
22k
はじめての Go * WASM * OCR
sgash708
1
130
Amazon Bedrockマルチエージェントコラボレーションを諦めてLangGraphに入門してみた
akihisaikeda
1
180
Featured
See All Featured
Designing for Performance
lara
605
68k
Scaling GitHub
holman
459
140k
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.2k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
248
1.3M
KATA
mclloyd
29
14k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
46
2.4k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
21
2.5k
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3k
Learning to Love Humans: Emotional Interface Design
aarron
273
40k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
330
21k
A Tale of Four Properties
chriscoyier
158
23k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
7
660
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