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
310
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
670
Tech Culture in Startups
alexbeletsky
0
210
TDD in JavaScript
alexbeletsky
4
840
This is Node.js
alexbeletsky
10
430
Likeastore
alexbeletsky
3
130
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.8k
Dynamic web development with Oak
alexbeletsky
1
610
Other Decks in Programming
See All in Programming
Software Architecture
hschwentner
6
2.3k
はじめてのDSPy - 言語モデルを『プロンプト』ではなく『プログラミング』するための仕組み
masahiro_nishimi
4
16k
React Nativeならぬ"Vue Native"が実現するかも?_新世代マルチプラットフォーム開発フレームワークのLynxとLynxのVue.js対応を追ってみよう_Vue Lynx
yut0naga1_fa
2
1.8k
Foundation Modelsを実装日本語学習アプリを作ってみた!
hypebeans
0
130
NixOS + Kubernetesで構築する自宅サーバーのすべて
ichi_h3
0
1.2k
AIと人間の共創開発!OSSで試行錯誤した開発スタイル
mae616
2
820
他言語経験者が Golangci-lint を最初のコーディングメンターにした話 / How Golangci-lint Became My First Coding Mentor: A Story from a Polyglot Programmer
uma31
0
450
AI Agent 時代的開發者生存指南
eddie
4
2.2k
TransformerからMCPまで(現代AIを理解するための羅針盤)
mickey_kubo
7
5.6k
なんでRustの環境構築してないのにRust製のツールが動くの? / Why Do Rust-Based Tools Run Without a Rust Environment?
ssssota
14
47k
GC25 Recap: The Code You Reviewed is Not the Code You Built / #newt_gophercon_tour
mazrean
0
120
pnpm に provenance のダウングレード を検出する PR を出してみた
ryo_manba
1
160
Featured
See All Featured
The Illustrated Children's Guide to Kubernetes
chrisshort
49
51k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
16k
Building a Scalable Design System with Sketch
lauravandoore
463
33k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
36
6.1k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
1.7k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
34
2.5k
Principles of Awesome APIs and How to Build Them.
keavy
127
17k
Into the Great Unknown - MozCon
thekraken
40
2.1k
The Language of Interfaces
destraynor
162
25k
RailsConf 2023
tenderlove
30
1.3k
Producing Creativity
orderedlist
PRO
348
40k
We Have a Design System, Now What?
morganepeng
53
7.8k
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