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
An Introduction to Spies in RSpec
Search
Penelope Phippen
November 17, 2014
Technology
180
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
An Introduction to Spies in RSpec
Penelope Phippen
November 17, 2014
More Decks by Penelope Phippen
See All by Penelope Phippen
Introducing Rubyfmt
penelope_zone
0
630
How RSpec Works
penelope_zone
0
6.9k
Quick and easy browser testing using RSpec and Rails 5.1
penelope_zone
1
120
Teaching RSpec to play nice with Rails
penelope_zone
2
190
Little machines that eat strings
penelope_zone
1
150
What is processor (brighton ruby edition)
penelope_zone
0
150
What is processor?
penelope_zone
1
390
extremely defensive coding - rubyconf edition
penelope_zone
0
300
Agile, etc.
penelope_zone
2
270
Other Decks in Technology
See All in Technology
味覇で作るパスタが美味い - 20261001_yabaubuki.dev
livesense
PRO
0
110
生成AIで高い生産性を求められて、 悩み、乗り越えた話
mot_techtalk
2
150
自律型 AI をセキュアに実装!Gemini と MIG で作る動的コード実行環境
recruitengineers
PRO
1
230
子育てエンジニアの可処分時間が減っても成長を諦めない戦い方
sudoakiy
5
4.3k
Datadog の学び方 - あるいは、オブザーバビリティを学ぶとは何か
mananyuki
1
510
全人類(ほぼ)AWS Organizations の上でAWSを利用している、その世界を知る話
htan
1
130
並行性の問題を防げ!実践トランザクション入門
occhi
0
280
パッチ更新でterraform initが落ちた日
grimoh
1
100
AI駆動開発、viviONの1年 ── うまくいったこと・いかなかったこと
vivion
0
280
「事実」を「計測」して、「解釈」する 〜AWS Lambdaのメモリ最適解の見つけ方〜
maimyyym
0
120
プロダクト価値を、 チームが使える判断軸に変える
vivion
0
140
スキルを作る、その前に!複数人で使われるスキルを 作るためのプロセス
junkifurukawa
2
370
Featured
See All Featured
Designing for Performance
lara
612
70k
Side Projects
sachag
456
43k
Impact Scores and Hybrid Strategies: The future of link building
tamaranovitovic
0
450
Testing 201, or: Great Expectations
jmmastey
46
8.3k
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
1
340
Evolving SEO for Evolving Search Engines
ryanjones
0
310
First, design no harm
axbom
PRO
2
1.3k
Leo the Paperboy
mayatellez
10
2.4k
The SEO identity crisis: Don't let AI make you average
varn
0
580
Max Prin - Stacking Signals: How International SEO Comes Together (And Falls Apart)
techseoconnect
PRO
0
480
Rebuilding a faster, lazier Slack
samanthasiow
85
9.7k
Automating Front-end Workflow
addyosmani
1369
210k
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]