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
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
610
How RSpec Works
penelope_zone
0
6.8k
Quick and easy browser testing using RSpec and Rails 5.1
penelope_zone
1
110
Teaching RSpec to play nice with Rails
penelope_zone
2
180
Little machines that eat strings
penelope_zone
1
130
What is processor (brighton ruby edition)
penelope_zone
0
140
What is processor?
penelope_zone
1
390
extremely defensive coding - rubyconf edition
penelope_zone
0
290
Agile, etc.
penelope_zone
2
260
Other Decks in Technology
See All in Technology
【Cyber-sec+】経営層を"動かす"ための考え方
hssh2_bin
0
190
失敗を資産に変えるClaude Code
shinyasaita
0
680
やさしいA2A入門
minorun365
PRO
12
1.9k
AIネイティブな開発のサプライチェーンリスク対策 〜激動の開発現場でリスクに立ち向かう〜【ZennFes】
cscengineer
PRO
2
130
SONiC Scale-Up Working Group から探る Scale-UpやUltraEthernet機能の実装方法
ebiken
PRO
2
350
2026 TECHFRESH 畢業分享會 - AI-Native 重塑軟體工程與虛擬講師
line_developers_tw
PRO
0
1.1k
中期計画、2回作ってみた ~業務委託と正社員、両方の視点から~
demaecan
1
910
気軽に使える"情報のハブ"としてのNotion活用 〜フロー情報の集積点 と、 Claude Code × Notion AI〜
syucream
1
140
Bedrock AgentCore RuntimeでAuth0 Changelog調査AIをアップグレードした話
t5u8a5a
1
160
エラーバジェットのアラートのタイミングを考える.pdf
kairim0
0
150
2026TECHFRESH畢業分享會 - Lightning Talk - 打造精準高效的 MCP 設計模式與測試實務
line_developers_tw
PRO
0
1.1k
AI駆動開発を通して感じた、 AI時代のデザイナーの役割変化
whisaiyo
3
2.2k
Featured
See All Featured
4 Signs Your Business is Dying
shpigford
187
22k
Building a Modern Day E-commerce SEO Strategy
aleyda
45
9.1k
Reflections from 52 weeks, 52 projects
jeffersonlam
356
21k
Marketing Yourself as an Engineer | Alaka | Gurzu
gurzu
0
240
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
1
620
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
659
62k
Between Models and Reality
mayunak
4
340
Thoughts on Productivity
jonyablonski
76
5.2k
Heart Work Chapter 1 - Part 1
lfama
PRO
7
36k
職位にかかわらず全員がリーダーシップを発揮するチーム作り / Building a team where everyone can demonstrate leadership regardless of position
madoxten
62
54k
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
170
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
28
3.5k
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]