Upgrade to PRO for Only $50/Year—Limited-Time Offer! 🔥
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Front-end Testing with CasperJS
Search
vitrum.zhu
February 19, 2013
Programming
3
180
Front-end Testing with CasperJS
Front-end Testing with CasperJS
vitrum.zhu
February 19, 2013
Tweet
Share
Other Decks in Programming
See All in Programming
[AtCoder Conference 2025] LLMを使った業務AHCの上⼿な解き⽅
terryu16
5
700
宅宅自以為的浪漫:跟 AI 一起為自己辦的研討會寫一個售票系統
eddie
0
530
これならできる!個人開発のすゝめ
tinykitten
PRO
0
130
Context is King? 〜Verifiability時代とコンテキスト設計 / Beyond "Context is King"
rkaga
10
1.4k
Canon EOS R50 V と R5 Mark II 購入でみえてきた最近のデジイチ VR180 事情、そして VR180 静止画に活路を見出すまで
karad
0
130
AI Agent Dojo #4: watsonx Orchestrate ADK体験
oniak3ibm
PRO
0
110
Python札幌 LT資料
t3tra
6
1k
Navigating Dependency Injection with Metro
l2hyunwoo
1
170
Rubyで鍛える仕組み化プロヂュース力
muryoimpl
0
160
組み合わせ爆発にのまれない - 責務分割 x テスト
halhorn
1
160
新卒エンジニアのプルリクエスト with AI駆動
fukunaga2025
0
230
著者と進める!『AIと個人開発したくなったらまずCursorで要件定義だ!』
yasunacoffee
0
160
Featured
See All Featured
Are puppies a ranking factor?
jonoalderson
0
2.4k
Measuring & Analyzing Core Web Vitals
bluesmoon
9
710
The Illustrated Children's Guide to Kubernetes
chrisshort
51
51k
Paper Plane (Part 1)
katiecoart
PRO
0
1.9k
Redefining SEO in the New Era of Traffic Generation
szymonslowik
1
160
How to Get Subject Matter Experts Bought In and Actively Contributing to SEO & PR Initiatives.
livdayseo
0
29
How to optimise 3,500 product descriptions for ecommerce in one day using ChatGPT
katarinadahlin
PRO
0
3.4k
Writing Fast Ruby
sferik
630
62k
First, design no harm
axbom
PRO
1
1.1k
Odyssey Design
rkendrick25
PRO
0
430
Test your architecture with Archunit
thirion
1
2.1k
Optimizing for Happiness
mojombo
379
70k
Transcript
Front-‐end Tes,ng with CasperJS Glamour Sales
China Vitrum Zhu 2013.2
• Old way and new way • About CasperJS
• Unit Test • UI Test
The finger and eye will told you. Old!
• Headless browser • Based on Webkit •
Controllable by command line • Full Javascript API
WebKit inside
CasperJS • browsing naviga,on steps • filling & submiRng
forms • capturing screenshots • tes,ng remote DOM • logging events • downloading resources • wri,ng func,onal test suites, saving results (with Node.js we can save results to any format. Like XML, TXT, JSON)
Quick Overview
Quick Overview Now run the following in the terminal:
casperjs test duckduck.js You should get something cool like the following:
CasperJS @ GLS • Web Crawler (web page spider)
• Simula,on Client access • Help Barnish create cache before customer visit
More techniques • hbp://Nodejs.org • hbp://casperjs.org • hbp://phantomjs.org/
Thanks! @vitrum Fork it! hbps://github.com/vitrum/nm-‐test/tree/ master/casperjs