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
PHPUnit
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
landish
May 29, 2015
Programming
0
110
PHPUnit
landish
May 29, 2015
Tweet
Share
More Decks by landish
See All by landish
Anatomy Of The Web
landish
1
190
Markdown
landish
0
160
Introduction to Ionic Framework
landish
0
100
Some Modern Tools for Developers
landish
0
130
Introduction to GIT
landish
0
66
Other Decks in Programming
See All in Programming
OSSとなったswift-buildで Xcodeのビルドを差し替えられるため 自分でXcodeを直せる時代になっている ダイアモンド問題編
yimajo
3
610
Data-Centric Kaggle
isax1015
2
770
MDN Web Docs に日本語翻訳でコントリビュート
ohmori_yusuke
0
640
Smart Handoff/Pickup ガイド - Claude Code セッション管理
yukiigarashi
0
130
Oxlintはいいぞ
yug1224
5
1.3k
AI時代の認知負荷との向き合い方
optfit
0
150
Basic Architectures
denyspoltorak
0
660
AIによるイベントストーミング図からのコード生成 / AI-powered code generation from Event Storming diagrams
nrslib
2
1.8k
フロントエンド開発の勘所 -複数事業を経験して見えた判断軸の違い-
heimusu
7
2.8k
[KNOTS 2026登壇資料]AIで拡張‧交差する プロダクト開発のプロセス および携わるメンバーの役割
hisatake
0
250
【卒業研究】会話ログ分析によるユーザーごとの関心に応じた話題提案手法
momok47
0
190
生成AIを使ったコードレビューで定性的に品質カバー
chiilog
1
260
Featured
See All Featured
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
5.8k
Future Trends and Review - Lecture 12 - Web Technologies (1019888BNR)
signer
PRO
0
3.2k
Lightning talk: Run Django tests with GitHub Actions
sabderemane
0
110
The Cult of Friendly URLs
andyhume
79
6.8k
The Spectacular Lies of Maps
axbom
PRO
1
520
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
508
140k
More Than Pixels: Becoming A User Experience Designer
marktimemedia
3
320
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
0
170
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
430
AI Search: Where Are We & What Can We Do About It?
aleyda
0
6.9k
Raft: Consensus for Rubyists
vanstee
141
7.3k
Navigating Team Friction
lara
192
16k
Transcript
Unit Testing With PHPUnit https://phpunit.de/
Test, that the code you wrote, actually works. Concept
Why? • Code Quality • Changes Does Not Break Anything
• Easy Contribution • Speed Up Development • Continuous Integration • Sleep At Night
Testing In Browser
Installation Old Way New (Modern) Way https://phpunit.de/manual/current/en/installation.html
Configuration - phpunit.xml(.dist) https://phpunit.de/manual/current/en/appendixes.configuration.html
File Structure |--src/ |----Example.php |--tests/ |----ExampleTest.php |--phpunit.xml
Example Test Case <?php class ExampleTest extends PHPUnit_Framework_TestCase { //
… public function testExample() { // … } // … }
https://phpunit.de/manual/current/en/appendixes.assertions.html Assertions
https://phpunit.de/manual/current/en/appendixes.annotations.html @Annotations
Test CLI
PHPUnit with PHPStorm
https://github.com/Landish/Pagination Showcase
<Live Code/>