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
9 ways to test your spaghetti code
Search
Mads Opheim
May 30, 2019
Technology
0
36
9 ways to test your spaghetti code
From Nordic Testing Days 2019
Mads Opheim
May 30, 2019
Tweet
Share
More Decks by Mads Opheim
See All by Mads Opheim
Modern Java App Development in the Cloud
madsopheim
0
47
IoT Powered by MicroProfile - JFuture
madsopheim
0
550
IoT Powered by MicroProfile - MakeIT
madsopheim
0
25
IoT powered by MicroProfile
madsopheim
0
30
9 ways to test your spaghetti code
madsopheim
0
130
Domain driven design in the real world
madsopheim
0
370
Make your tests tell the story of your domain
madsopheim
0
87
IoT powered by MicroProfile
madsopheim
0
44
9_ways_to_test_your_spaghetti_code_-_Devoxx_Ukraine.pdf
madsopheim
0
59
Other Decks in Technology
See All in Technology
AWS表彰プログラムとキャリアについて
naoki_0531
1
150
[MIRU2025]Preference Optimization for Multimodal Large Language Models for Image Captioning Tasks
keio_smilab
PRO
0
120
少人数でも回る! DevinとPlaybookで支える運用改善
ishikawa_pro
4
1.8k
The Madness of Multiple Gemini CLIs Developing Simultaneously with Jujutsu
gunta
1
2.8k
【CEDEC2025】LLMを活用したゲーム開発支援と、生成AIの利活用を進める組織的な取り組み
cygames
PRO
1
1.8k
Expertise as a Service via MCP
yodakeisuke
1
160
Vision Language Modelと自動運転AIの最前線_20250730
yuyamaguchi
2
800
Gemini in Android Studio - Google I/O Bangkok '25
akexorcist
0
100
20250728 MCP, A2A and Multi-Agents in the future
yoshidashingo
1
120
マルチモーダル基盤モデルに基づく動画と音の解析技術
lycorptech_jp
PRO
2
280
[TechNight #91] Oracle Database 最新パフォーマンス分析手法
oracle4engineer
PRO
3
210
私とAWSとの関わりの歩み~意志あるところに道は開けるかも?~
nagisa53
1
140
Featured
See All Featured
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
50
5.5k
The Cult of Friendly URLs
andyhume
79
6.5k
jQuery: Nuts, Bolts and Bling
dougneiner
63
7.8k
What's in a price? How to price your products and services
michaelherold
246
12k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
667
120k
Build your cross-platform service in a week with App Engine
jlugia
231
18k
Why You Should Never Use an ORM
jnunemaker
PRO
58
9.5k
Statistics for Hackers
jakevdp
799
220k
The Power of CSS Pseudo Elements
geoffreycrofte
77
5.9k
Learning to Love Humans: Emotional Interface Design
aarron
273
40k
4 Signs Your Business is Dying
shpigford
184
22k
Speed Design
sergeychernyshev
32
1k
Transcript
Nordic Testing Days 9 ways to test your spaghetti code
Mads Opheim @MadsOpheim 1
Tere! I’m Mads. I’m a developer 2
Spaghetti code? 3
The 9 ways 4
5 1. Test all or Test small
6 2. Set your dependencies
7
Singletons 8
3. Package-protect problematic parts 9
Tools for your toolbox 10
4. Do simple refactorings to get your code under test
11
In general: untangling and looking at one part at a
time 12
You’re not as smart as you think you are 13
Well-designed code is testable code 14
15 5. Help your team
You’ll forget things 16
6. Run your tests - and care 17
7. Feature toggles 18
8. One mile at a time 19
Refactor in separate commits 20
9. Test-driven development 21
Test-driven spaghetti 22
TDD on legacy code in practice 23
Tip 10, 11 and onwards 24
25 The Deadline For Kunngjøring Is Four Weeks()
26 Properties For Namsmann Mainly Follow The Same Rules as
Hovedstevnevitne()
You’ll do stupid things - and that’s ok 27
Be consistent 28
Give me more @lisacrispin, @lisihocke, @techgirl1908, @maaretp... 29
Key takeaways 30 1. Good code design improves testability 2.
TDD on spaghetti code: TDD + test spaghetti code 3. Write tests for you legacy code - you can do it!
Thank you! @MadsOpheim
[email protected]
31