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
An Introduction to Spies in RSpec
Search
Penelope Phippen
November 17, 2014
Technology
0
160
An Introduction to Spies in RSpec
Penelope Phippen
November 17, 2014
Tweet
Share
More Decks by Penelope Phippen
See All by Penelope Phippen
Introducing Rubyfmt
penelope_zone
0
560
How RSpec Works
penelope_zone
0
6.6k
Quick and easy browser testing using RSpec and Rails 5.1
penelope_zone
1
81
Teaching RSpec to play nice with Rails
penelope_zone
2
130
Little machines that eat strings
penelope_zone
1
98
What is processor (brighton ruby edition)
penelope_zone
0
110
What is processor?
penelope_zone
1
350
extremely defensive coding - rubyconf edition
penelope_zone
0
260
Agile, etc.
penelope_zone
2
220
Other Decks in Technology
See All in Technology
CI/CD/IaC 久々に0から環境を作ったらこうなりました
kaz29
1
210
Lambda Web Adapterについて自分なりに理解してみた
smt7174
5
150
より良いプロダクトの開発を目指して - 情報を中心としたプロダクト開発 #phpcon #phpcon2025
bengo4com
1
3.2k
Backlog ユーザー棚卸しRTA、多分これが一番早いと思います
__allllllllez__
1
120
開発生産性を組織全体の「生産性」へ! 部門間連携の壁を越える実践的ステップ
sudo5in5k
1
4k
使いたいMCPサーバーはWeb APIをラップして自分で作る #QiitaBash
bengo4com
0
1.5k
Fabric + Databricks 2025.6 の最新情報ピックアップ
ryomaru0825
1
160
AWS Organizations 新機能!マルチパーティ承認の紹介
yhana
1
240
SmartNewsにおける 1000+ノード規模 K8s基盤 でのコスト最適化 – Spot・Gravitonの大規模導入への挑戦
vsanna2
0
100
Flutter向けPDFビューア、pdfrxのpdfium WASM対応について
espresso3389
0
110
生成AI開発案件におけるClineの業務活用事例とTips
shinya337
0
200
AI導入の理想と現実~コストと浸透〜
oprstchn
0
170
Featured
See All Featured
Rebuilding a faster, lazier Slack
samanthasiow
82
9.1k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
44
2.4k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
7
730
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
48
2.9k
Faster Mobile Websites
deanohume
307
31k
Testing 201, or: Great Expectations
jmmastey
42
7.6k
A designer walks into a library…
pauljervisheath
207
24k
Optimising Largest Contentful Paint
csswizardry
37
3.3k
It's Worth the Effort
3n
185
28k
GitHub's CSS Performance
jonrohan
1031
460k
The Invisible Side of Design
smashingmag
301
51k
The Language of Interfaces
destraynor
158
25k
Transcript
An Introduction to Spies in RSpec
a!/samphippen
Feel free to ask Questions
Testing
We are the people that test the code
Why do we test our code?
x`
None
Tests help us find bugs
and then never see them again
Some tests provide design feedback on our code
Kinds of test
Integrated test Fake nothing
Isolated test Fake everything
and a spectrum in between
Why do we fake things?
None
Kinds of fake
Stub Fake a response to some method call
Mock Expect a method will be called in the future
Spy Record calls made and then assert after the fact
Let’s write some tests
x
Let’s have some questions !!/samphippen
[email protected]
Feel free to ask Questions
RSpec RSpec ! ! RSpec 3
Let’s have some questions a!/samphippen
[email protected]