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
JLPDevs - Web Application Unit Testing: Strateg...
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
JLP Community
December 05, 2015
Programming
55
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
JLPDevs - Web Application Unit Testing: Strategy and Tools
JLP Community
December 05, 2015
More Decks by JLP Community
See All by JLP Community
JLP Community Profile
jlpcommunity
0
60
JLPDevs - Optimization Tooling for Modern Web App Development
jlpcommunity
3
210
Other Decks in Programming
See All in Programming
ChromeでローカルLLM
ryu1013
0
120
設計次第でAIコードの読む量は減らせる / designing-for-code-reading
minodriven
35
16k
TechTown - Creating Composable Callables in Contemporary C++
rollbear
0
110
Starting & Sustaining Code-Based E2E Testing for Non-Coding QA Teams( #jasstniigata )
teyamagu
PRO
1
980
sbt 2.0: takeoff
eed3si9n
0
150
現場と育てるRailsモデリング 〜Spreadsheetから始めたモデル設計〜
siroemk
1
180
パスワード再設定メールのURLについて知っておこう
uyuki234
0
140
R8 の設定見直しでアプリサイズ削減
andpad
0
210
contenteditable と日本語入力に向き合う
colorful12
0
190
[ハンズオン]AIへの指示だけで「五目並べ」を作ってみよう
satoshi256kbyte
1
370
UPDATE をやめる — EF Core でマスタをバージョン管理する
panda728
PRO
0
1.2k
HTML-in-Canvasで作る未来のWeb UI表現
clockmaker
4
4.8k
Featured
See All Featured
Exploring anti-patterns in Rails
aemeredith
4
530
Neural Spatial Audio Processing for Sound Field Analysis and Control
skoyamalab
0
560
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
880
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
3k
Sam Torres - BigQuery for SEOs
techseoconnect
PRO
0
580
Lessons Learnt from Crawling 1000+ Websites
charlesmeaden
PRO
1
1.6k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
23k
Abbi's Birthday
coloredviolet
4
10k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
31
3.4k
Thoughts on Productivity
jonyablonski
76
5.4k
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
1
1.7k
Taking LLMs out of the black box: A practical guide to human-in-the-loop distillation
inesmontani
PRO
3
2.4k
Transcript
Web Application Unit Testing: Strategy and Tools Presented by: Salman
El Farisi 05 Desember 2015 @ code margonda
Let's Move On Runnable Code Testable Code
Not So Testable Code
Better Version
Better Version (2)
Testing Pyramid
Web Application Unit Testing Challenge: Too much dependency Network
(HTTP Request) Database Third Party Library File System (upload / download file) Tools: PHPUnit (Unit testing framework) Mockery (Mock Object) Faker (Fake Object) PHP-DI / Pimple (Dependency Injection Library)
Mockery
Faker
Web Application Unit Testing (2)
Web Application Unit Testing (3)
Web Application Unit Testing (3) Assertion: Compare expected and actual
value AssertTrue() AssertNotNull() AssertEquals() AssertArrayHasKey() AssertClassHasAttribute() Etc. https://phpunit.de/manual/current/en/phpunit-book.html#appendixes.assertions
Mock Object RoleController.php Connect to database
Mock Object (2) RoleControllerTest.php Control the 'Role' class behaviour so
it wont touch the database
Fake Object Create fake object
Thank You :)