Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
My Tests are a Mess: The Other Junk Drawer
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Christopher Sexton
June 07, 2014
Technology
78
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
My Tests are a Mess: The Other Junk Drawer
Slides from RubyNation
Christopher Sexton
June 07, 2014
More Decks by Christopher Sexton
See All by Christopher Sexton
Unraveling the Cable: How Action Cable Works
csexton
1
7.1k
Ruby's Killer Feature: The Community
csexton
0
100
Other Decks in Technology
See All in Technology
AI駆動で「他アプリの音を加工できる」アプリを作った
satomasahiro2005
0
170
PHPカンファレンス関西の招待状 / Invitation to PHP Conference Kansai
ykanoh
0
200
CTO Night|NotionのAIエージェントとFDE
kzkhykw1991
0
220
AI導入は済んだ。次は統制を作り替える番だ_AI×開発組織 Summit 2026
techtekt
PRO
0
320
専門領域のAIをどう評価するか
bengo4com
2
280
夫婦で子育てするための育児標準化
codmoninc
PRO
0
440
20261017福岡devIO 「AIは"良いダッシュボード"を作れるか?
jtakeda
0
180
トークン化預金DCJPYの取り組みと活用ユースケース
finengine
0
120
『SAR衛星データ解析入門』のご紹介とその応用
syuchimu
0
120
パスキーの自動テストはどこまでいけるのか
teamlab
PRO
0
280
⾮構造化データを価値に変える AI エージェント基盤とその組織
ivry_presentationmaterials
0
200
JAWSUG TOHOKU 青森支部 「LoGoチャット」のAWS移行で 乗り越えたこと
taketakekaho
0
340
Featured
See All Featured
Context Engineering - Making Every Token Count
addyosmani
9
1.2k
The Language of Interfaces
destraynor
162
27k
Joys of Absence: A Defence of Solitary Play
codingconduct
1
550
Deep Space Network (abreviated)
tonyrice
0
370
The Illustrated Children's Guide to Kubernetes
chrisshort
51
53k
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
570
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
450
GraphQLとの向き合い方2022年版
quramy
50
15k
SEOcharity - Dark patterns in SEO and UX: How to avoid them and build a more ethical web
sarafernandez
0
300
[Rails World 2026] Durable orchestration on Rails: from continuation to workflow
palkan
1
750
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
130k
Building Applications with DynamoDB
mza
96
7.2k
Transcript
None
None
None
The Other Junk Drawer
Long live TDD TDD is Dead
Thanks for your time! Any questions? $ rm -rf ./tests
Hi I am Aaron @cupakromer
Hi I am Chris @crsexton
None
And mess with the folks next door Let’s wake up
Like I did something super amazing On 3, say “woah”
This will really confuse them On 3, say “Moo”
I feel more awake That’s better
My Tests are a Mess
SRSLY How did it get this way?
10,000 ft
None
Goal
Write code that I can understand when I come back
to it in 6 months My Real Goal
Simple
The Plague It’s easy to build something complicated
Complicated vs. Complex
None
What to Test?
Acceptance Keep the business happy. Make things work.
Units Check all the bits and pieces
Units Sandi is a Wizard Magic Tricks of Testing bit.ly/sandi-wizard
In between Controllers Views Form Object Policies
Overlap Wait a second, that won’t work
None
Mise en Place Put your toys away as you go
Directory Structure mirror `/lib` (and `/app`)
Group Logically Put related things close together
Manage Setup Very carefully
Setup
Setup
Setup
Setup
Setup
Setup
Setup
Setup
Tests should help you understand what you need to test
(state) Class declarations tell you what behaviors you need to test
None
Priority
Intent
Habit
None
Awesome Tests “Bad” tests are 100% more awesome than no
tests
None
None
None
Pictures from TeeFury, Woot, Reddit, Disney, United Artists, Lucasfilm and
others. Images used under fair use. See Section 3.3: Use of Images for Peer Conferences of the Fair Use Guidelines for Digital Images http://copyright.lib.utexas.edu/imagguid.html Credits
Classic Arrange Act Assert
Arrange All the necessary preconditions and inputs
Act On the object or method under test
Assert That the expected results occurred