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
Yay! Mocks!
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Corey Haines
June 26, 2012
Programming
4
310
Yay! Mocks!
Discussion about usage of test-doubles in driving design
Corey Haines
June 26, 2012
Tweet
Share
More Decks by Corey Haines
See All by Corey Haines
Getting the most out of a conference
coreyhaines
3
260
Other Decks in Programming
See All in Programming
What Spring Developers Should Know About Jakarta EE
ivargrimstad
0
700
AI活用のコスパを最大化する方法
ochtum
0
340
Kubernetesでセルフホストが簡単なNewSQLを求めて / Seeking a NewSQL Database That's Simple to Self-Host on Kubernetes
nnaka2992
0
180
Coding at the Speed of Thought: The New Era of Symfony Docker
dunglas
0
1k
How to stabilize UI tests using XCTest
akkeylab
0
140
Codex CLI でつくる、Issue から merge までの開発フロー
amata1219
0
150
今からFlash開発できるわけないじゃん、ムリムリ! (※ムリじゃなかった!?)
arkw
0
160
Everything Claude Code OSS詳細 — 5層構造の中身と導入方法
targe
0
150
Agentic AI: Evolution oder Revolution
mobilelarson
PRO
0
200
20260315 AWSなんもわからん🥲
chiilog
2
180
Java 21/25 Virtual Threads 소개
debop
0
280
Goの型安全性で実現する複数プロダクトの権限管理
ishikawa_pro
2
1.4k
Featured
See All Featured
How to Get Subject Matter Experts Bought In and Actively Contributing to SEO & PR Initiatives.
livdayseo
0
91
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
21
1.4k
The SEO identity crisis: Don't let AI make you average
varn
0
420
Designing for Timeless Needs
cassininazir
0
170
BBQ
matthewcrist
89
10k
Chasing Engaging Ingredients in Design
codingconduct
0
150
SERP Conf. Vienna - Web Accessibility: Optimizing for Inclusivity and SEO
sarafernandez
1
1.4k
[SF Ruby Conf 2025] Rails X
palkan
2
860
My Coaching Mixtape
mlcsv
0
86
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
280
Why You Should Never Use an ORM
jnunemaker
PRO
61
9.8k
The Language of Interfaces
destraynor
162
26k
Transcript
Tuesday, June 26, 2012
YAY! Mocks! @coreyhaines Nordicy RubyConf 2012 Tuesday, June 26, 2012
YAY! Test Doubles! @coreyhaines Nordicy RubyConf 2012 Tuesday, June 26,
2012
Zak! Tuesday, June 26, 2012
Test-Driven Development Tuesday, June 26, 2012
Object-Oriented is about messages Tuesday, June 26, 2012
Object-Oriented is about interactions Tuesday, June 26, 2012
Object-Oriented is about services Tuesday, June 26, 2012
Roles vs Things Tuesday, June 26, 2012
Test-Driven Development Tuesday, June 26, 2012
Test-First Development Tuesday, June 26, 2012
Test-Driven vs Test-First Tuesday, June 26, 2012
Reaction to pain Tuesday, June 26, 2012
Test-First -> Change Tests Tuesday, June 26, 2012
Test-Driven -> Change Design Tuesday, June 26, 2012
Test-Doubles Often Highlight Pain Tuesday, June 26, 2012
Zak! Tuesday, June 26, 2012
Examples Tuesday, June 26, 2012
Showing list of Coderetreats for today Tuesday, June 26, 2012
You have to change your test When you change this
hash Tuesday, June 26, 2012
Feels Very Fragile Tuesday, June 26, 2012
PAIN! Tuesday, June 26, 2012
Discomfort! Tuesday, June 26, 2012
Tuesday, June 26, 2012
Why is this information relevant to the controller? Tuesday, June
26, 2012
Bypassing Layers Tuesday, June 26, 2012
This is odd Tuesday, June 26, 2012
Controller calling database? Tuesday, June 26, 2012
Controller should know ‘WHAT’ not ‘HOW’ Tuesday, June 26, 2012
Better to insert a layer Tuesday, June 26, 2012
Controller Business-Oriented Services DB Tuesday, June 26, 2012
What, not How Tuesday, June 26, 2012
Better to delegate the How Tuesday, June 26, 2012
TDD is about design Tuesday, June 26, 2012
Change design, not tests Tuesday, June 26, 2012
Focusing on usage Tuesday, June 26, 2012
I like Presenters! Tuesday, June 26, 2012
Tuesday, June 26, 2012
double depending on doubles?? Tuesday, June 26, 2012
UGH! Tuesday, June 26, 2012
Too much detail at this level? Jumping levels of abstraction?
Tuesday, June 26, 2012
Change design to fix pain Tuesday, June 26, 2012
Simplify our example Tuesday, June 26, 2012
Simplify our example Tuesday, June 26, 2012
Much simpler, more focused on what the controller needs to
know Tuesday, June 26, 2012
Tuesday, June 26, 2012
TDD is about refactoring Tuesday, June 26, 2012
TDD is about refactoring away from discomfort Tuesday, June 26,
2012
Changing your design, to fix pain Tuesday, June 26, 2012
Test doubles can help highlight and fix pain Tuesday, June
26, 2012
Take-Home Challenge Tuesday, June 26, 2012
Tuesday, June 26, 2012
Coupled Roles Tuesday, June 26, 2012
Unnecessary noise Tuesday, June 26, 2012
or false positive if yesterday’s or tomorrow’s are not created
in database Tuesday, June 26, 2012
How to change design to fix this? Tuesday, June 26,
2012
Thanks! @coreyhaines Nordicy RubyConf 2012 font inspiration: bit.ly/corey-sans Tuesday, June
26, 2012