Lock in $30 Savings on PRO—Offer Ends Soon! ⏳
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Test-driven development for TYPO3
Search
Oliver Klee
June 21, 2014
Programming
0
160
Test-driven development for TYPO3
Slides of my workshop on T3DD14
Oliver Klee
June 21, 2014
Tweet
Share
More Decks by Oliver Klee
See All by Oliver Klee
Gewaltfreie Kommunikation: ein Crashkurs
oliverklee
0
76
Team-Management-Plattform
oliverklee
0
64
Vertrauen in Teams & Führung
oliverklee
0
240
Software-Qualität von TYPO3-Extensions automatisieren
oliverklee
0
38
Vertrauen in Teams & Führung
oliverklee
0
150
Testing von TYPO3-Extensions
oliverklee
0
75
Software-Qualität von Extensions automatisieren
oliverklee
1
52
Content-Synchronisierung
oliverklee
0
160
Gewaltfreie Kommunikation: ein Crashkurs
oliverklee
0
320
Other Decks in Programming
See All in Programming
手が足りない!兼業データエンジニアに必要だったアーキテクチャと立ち回り
zinkosuke
0
740
大体よく分かるscala.collection.immutable.HashMap ~ Compressed Hash-Array Mapped Prefix-tree (CHAMP) ~
matsu_chara
2
220
chocoZAPサービス予約システムをNuxtで内製化した話
rizap_tech
0
160
tsgolintはいかにしてtypescript-goの非公開APIを呼び出しているのか
syumai
7
2.2k
C-Shared Buildで突破するAI Agent バックテストの壁
po3rin
0
390
Socio-Technical Evolution: Growing an Architecture and Its Organization for Fast Flow
cer
PRO
0
360
ゲームの物理 剛体編
fadis
0
350
AIコーディングエージェント(Gemini)
kondai24
0
230
Microservices rules: What good looks like
cer
PRO
0
1.5k
FluorTracer / RayTracingCamp11
kugimasa
0
230
WebRTC と Rust と8K 60fps
tnoho
2
2k
Cap'n Webについて
yusukebe
0
130
Featured
See All Featured
RailsConf 2023
tenderlove
30
1.3k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
231
22k
The Art of Programming - Codeland 2020
erikaheidi
56
14k
Product Roadmaps are Hard
iamctodd
PRO
55
12k
The Power of CSS Pseudo Elements
geoffreycrofte
80
6.1k
A designer walks into a library…
pauljervisheath
210
24k
Faster Mobile Websites
deanohume
310
31k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
1.1k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
122
21k
Building a Modern Day E-commerce SEO Strategy
aleyda
45
8.3k
Context Engineering - Making Every Token Count
addyosmani
9
520
Designing Dashboards & Data Visualisations in Web Apps
destraynor
231
54k
Transcript
Test-Driven Development for TYPO3 Oliver Klee, 2014-06-21 @oliklee
[email protected]
Unit tests?
Manual testing is cumbersome
Automated testing is fast
Unit tests for the Realty Manager extension
more than 1600 tests
in less than 60 seconds
Verify that your code does what you expect
Make sure that your changes won‘t break anything
Keep other coders from breaking your code
Don‘t break anything even in complex projects
Create a safety net for refactoring
Improve the structure of the code
Green feels good!
None
Know your tools
The phpunit extension has it all phpunit (TYPO3 extension) PHPUnit
(Composer package) Testrunner (back-end- module) Testrunner (CLI module) Testing framework for FE & DB
Let‘s get some terms straight
Test suite Test case Test Two tests meet in a
bar ... Assertion Test Test Test case
The life cycle of a unit test new FooTest(); setUp();
/** @test */ lifeIsGood(); tearDown();
Code test-first write test write code refactor
None
Use meaningful unit test names classCanBeInstantiated setTitleSetsTitle setSizeWithZeroThrowsException hasTitleForEmptyTitleReturnsFalse Name
the behavior. Name the preconditions. Mention the method. Dont‘t use "works" or "correctly". measureFrubbleWorksCorrectly