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
Testing Any Website Written in Any Language Wit...
Search
Prem Sichanugrist
November 16, 2014
Technology
1
180
Testing Any Website Written in Any Language With Capybara and RSpec
Presented at Barcamp Bangkhen 2014 on November 16, 2014.
Prem Sichanugrist
November 16, 2014
Tweet
Share
More Decks by Prem Sichanugrist
See All by Prem Sichanugrist
Working with Huge Databases and Tables
sikachu
1
92
What's coming in Rails 5.2, and sneak peek into Rails 6
sikachu
6
6k
Zero-downtime payment platforms
sikachu
2
260
Introduction to Active Support
sikachu
0
170
Hidden gems in Ruby on Rails
sikachu
5
290
Active Support Secrets
sikachu
1
270
Dependencies Testing With Appraisal And Bundler
sikachu
1
350
You have to test multiple versions of your gem's dependencies. You used Appraisal. It's super affective!
sikachu
0
330
Zero-downtime payment platforms
sikachu
1
130
Other Decks in Technology
See All in Technology
2時間で300+テーブルをデータ基盤に連携するためのAI活用 / FukuokaDataEngineer
sansan_randd
0
130
LIFF CLIとngrokを使ったLIFF/LINEミニアプリのお手軽実機確認
diggymo
0
230
Jamf Connect ZTNAとMDMで実現! 金融ベンチャーにおける「デバイストラスト」実例と軌跡 / Kyash Device Trust
rela1470
0
150
【CEDEC2025】大規模言語モデルを活用したゲーム内会話パートのスクリプト作成支援への取り組み
cygames
PRO
2
770
Agent Development Kitで始める生成 AI エージェント実践開発
danishi
0
120
マルチモーダル基盤モデルに基づく動画と音の解析技術
lycorptech_jp
PRO
4
530
金融サービスにおける高速な価値提供とAIの役割 #BetAIDay
layerx
PRO
1
740
AIエージェントを現場で使う / 2025.08.07 著者陣に聞く!現場で活用するためのAIエージェント実践入門(Findyランチセッション)
smiyawaki0820
6
690
リリース2ヶ月で収益化した話
kent_code3
1
190
【新卒研修資料】数理最適化 / Mathematical Optimization
brainpadpr
25
11k
Findy Freelance 利用シーン別AI活用例
ness
0
310
Oracle Cloud Infrastructure:2025年7月度サービス・アップデート
oracle4engineer
PRO
1
120
Featured
See All Featured
We Have a Design System, Now What?
morganepeng
53
7.7k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
332
22k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
44
2.4k
[RailsConf 2023] Rails as a piece of cake
palkan
56
5.7k
Navigating Team Friction
lara
188
15k
Measuring & Analyzing Core Web Vitals
bluesmoon
7
540
What's in a price? How to price your products and services
michaelherold
246
12k
Music & Morning Musume
bryan
46
6.7k
Become a Pro
speakerdeck
PRO
29
5.5k
RailsConf 2023
tenderlove
30
1.2k
Faster Mobile Websites
deanohume
308
31k
GitHub's CSS Performance
jonrohan
1031
460k
Transcript
Testing Any Website Written in Any Language With Capybara and
RSpec
Prem Sichanugrist @sikachu /sikachu
Testing
Acceptance Testing
High-level Testing
Assert From User's Perspective
Whole-Stack Testing
Acceptance Testing Frameworks • Cucumber (Ruby) • Mocha (JavaScript (node.js))
• Ranorex (C#, VB.NET)
Capybara + RSpec (Ruby)
Why You Should Write Acceptance Test
(this slide is intentionally left blank)
TL;DR • User flow is well-defined • Prevent future regression
after introducing new feature
Why Capybara + Rspec?
Clean & Clear Syntax
Very Well-Maintained
Very Flexible Easily swapping between drivers
Requirements
Requirements 1. RSpec - Testing Framework
Requirements 1. RSpec - Testing Framework 2. Capybara - Providing
DSL for Testing
Requirements 1. RSpec - Testing Framework 2. Capybara - Providing
DSL for Testing 3. Capybara Webkit - Webkit Backend with JS support
Demo
Steps • Install dependencies using Bundler • RSpec, Capybara, Capybara
Webkit • Run RSpec install • Require Capybara in spec_helper • Set Webkit as the driver • Done, start writing test!
http://git.io/bcbk-testing Demo Source Code
Before we're done ... • Bangkok.rb • Metting every last
Saturday afternoon • http://bit.ly/bangkokrb (Google Groups) • November Meeting - November 29, 2014 • Sign up: http://bit.ly/bangkokrb-nov2014
Thank You! Any Questions? Code: http://git.io/bcbk-testing Slide: http://bit.ly/bcbk-testing Follow me:
https://twitter.com/sikachu