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
Vue.js 單元測試 -Jest
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
CypressKuo
April 28, 2017
Technology
200
0
Share
Vue.js 單元測試 -Jest
Vue.js 單元測試 with Jest
CypressKuo
April 28, 2017
More Decks by CypressKuo
See All by CypressKuo
Deep-copying.pdf
cypresskuo
0
35
CSS_for_Web_Vitals.pdf
cypresskuo
0
39
談談_Code_review.pdf
cypresskuo
0
47
REST_vs_GraphQL_今夜はご注文はどっち.pdf
cypresskuo
0
23
CSS_重構.pdf
cypresskuo
0
27
跟上_JS_的腳步-ES2020.pdf
cypresskuo
0
30
Core_Web_Vitals.pdf
cypresskuo
0
55
這個時代人人都知道的敏捷開發.pdf
cypresskuo
0
62
Webassembly.pdf
cypresskuo
0
13
Other Decks in Technology
See All in Technology
M5Stack CoreS3とZephyr(RTOS)で Edge AIっぽいことしてみた
iotengineer22
0
280
CloudTrail を見つめ直してみる
kazzpapa3
1
110
The Journey of Box Building
tagomoris
4
3.3k
Percolatorを廃止し、マルチ検索サービスへ刷新した話 / Search Engineering Tech Talk 2026 Spring
visional_engineering_and_design
0
120
Cortex Codeのコスト見積ヒントご紹介
yokatsuki
0
110
Standards et agents IA : un tour d’horizon de MCP, A2A, ADK et plus encore
glaforge
0
190
[OAWTT26][THR1028] Oracle AI Database 26ai へのアップグレード:ベストプラクティスと最新情報
oracle4engineer
PRO
1
110
Do Ruby::Box dream of Modular Monolith?
joker1007
1
350
目的ファーストのハーネス設計 ~ハーネスの変更容易性を高めるための優先順位~
gotalab555
8
2.3k
基盤を育てる 外部SaaS連携の運用
gamonges_dresscode
1
120
MLOps導入のための組織作りの第一歩
akasan
0
360
AI와 협업하는 조직으로의 여정
arawn
0
510
Featured
See All Featured
svc-hook: hooking system calls on ARM64 by binary rewriting
retrage
2
220
Navigating Weather and Climate Data
rabernat
0
170
Bootstrapping a Software Product
garrettdimon
PRO
307
120k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
250
1.3M
Evolving SEO for Evolving Search Engines
ryanjones
0
180
WENDY [Excerpt]
tessaabrams
10
37k
Believing is Seeing
oripsolob
1
110
brightonSEO & MeasureFest 2025 - Christian Goodrich - Winning strategies for Black Friday CRO & PPC
cargoodrich
3
680
Groundhog Day: Seeking Process in Gaming for Health
codingconduct
0
150
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.7k
Balancing Empowerment & Direction
lara
6
1.1k
GraphQLとの向き合い方2022年版
quramy
50
15k
Transcript
Vue.js 單元測試 -Jest 2017/04/28 @前端組例會 cypresskuo
Jest Painless JavaScript Testing - Easy Setup - Instant Feedback
- Snapshot Testing - Zero configuration testing platform - Facebook 開源專案 2
Easy Setup Zero configuration testing platform 3
Instant Feedback --watch --watchAll 4
Snapshot Testing 將 React trees 或是其他可序列化的 UI 截取下來, 防止無意間修改到組件的某個部份。 -
server side render 5
6
其他功能 DOM Testing (需要其他元件 TestUtil) Mock Function 覆蓋率報告 --coverage http://stackoverflow.com/questions/26618243/how-do-i-read-an-istanbul-coverage-report
7
參考資料 http://facebook.github.io/jest/ https://vuejs.org/v2/guide/unit-testing.html http://laichuanfeng.com/work/jest-snapshot-and-dom-testing-in-react/ https://hackernoon.com/jest-for-all-episode-1-vue-js-d616bccbe186 8
感謝聆聽 9