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
Compiler Based Testing
Search
Xavier Gouchet
April 03, 2019
Programming
1
92
Compiler Based Testing
Xavier Gouchet
April 03, 2019
Tweet
Share
More Decks by Xavier Gouchet
See All by Xavier Gouchet
Libérez votre créativité
xgouchet
0
66
Unleash your Programming Creativity
xgouchet
0
110
Demystifying the Test Pyramid
xgouchet
1
360
Successfully Publishing a Tested, Upgradeable and Documented Open Source Library
xgouchet
0
62
Property Based Testing in Practice
xgouchet
0
55
Develop your CI tools
xgouchet
2
360
How to write a safe and reliable Open Source Library
xgouchet
1
230
Benchmarking your app's performance
xgouchet
0
180
Benchmarking your app's performance
xgouchet
0
85
Other Decks in Programming
See All in Programming
フロントエンドのディレクトリ構成どうしてる? Feature-Sliced Design 導入体験談
osakatechlab
8
4.1k
第5回日本眼科AI学会総会_AIコンテスト_3位解法
neilsaw
0
170
Discord Bot with AI -for English learners-
xin9le
1
120
HTTP compression in PHP and Symfony apps
dunglas
2
1.7k
fs2-io を試してたらバグを見つけて直した話
chencmd
0
220
プロダクトの品質に コミットする / Commit to Product Quality
pekepek
2
770
複雑な仕様に立ち向かうアーキテクチャ
myohei
0
170
ドメインイベント増えすぎ問題
h0r15h0
1
120
17年周年のWebアプリケーションにTanStack Queryを導入する / Implementing TanStack Query in a 17th Anniversary Web Application
saitolume
0
250
Haze - Real time background blurring
chrisbanes
1
500
MCP with Cloudflare Workers
yusukebe
2
220
선언형 UI에서의 상태관리
l2hyunwoo
0
140
Featured
See All Featured
GitHub's CSS Performance
jonrohan
1030
460k
The Language of Interfaces
destraynor
154
24k
Bash Introduction
62gerente
608
210k
StorybookのUI Testing Handbookを読んだ
zakiyama
27
5.3k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
5
440
Faster Mobile Websites
deanohume
305
30k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
26
1.9k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
Put a Button on it: Removing Barriers to Going Fast.
kastner
59
3.6k
Java REST API Framework Comparison - PWX 2021
mraible
PRO
28
8.3k
[RailsConf 2023] Rails as a piece of cake
palkan
53
5k
A Tale of Four Properties
chriscoyier
157
23k
Transcript
@xgouchet Compiler based Testing CodeMobile UK 2019 - Chester
@xgouchet About me… Xavier F. Gouchet Android developer since the
Cupcake years Lead Android Engineer at WorkWell @xgouchet on every social network you can think of… 2
@xgouchet Testing is Hard Let’s let the compiler do most
of the hard work for us 3
@xgouchet Kotlin / Swift ▧ Statically Typed ▧ Strong Typed
▧ Type Safe ▧ Type Inference 4
@xgouchet Basic use case — JSON { "id" : 481516,
"title" : "Lorem ipsum dolor sit amet…", "picture" : "https://cloudhost.com/5162342", "created": 1553631328 } 5
@xgouchet Basic use case — App Model data class Event(
val id: Int, val title: String, val picture: String, val created: Int } 6
@xgouchet Primitive Aversion Primitives are lightweight… but lack context 7
@xgouchet Use existing types ▧ Integrated in framework and libraries
▧ Zero additional work data class Event( … val created: Date } 8
@xgouchet Type Alias ▧ Give context ▧ Prevent invalid assignements
▧ Ease Maintenance typealias Id = Int data class Event( val id: Id, … } 9
@xgouchet Type Checking ▧ Limit Primitive Scope ▧ Validate data
data class Url(val value: String) { init { val parsedUrl = URL(value) } } data class Event( … val picture: Url } 10
@xgouchet Additional gains 11
@xgouchet Bonus ▧ Share common operations ▧ Force explicit types
▧ Simplify complex structure 12
@xgouchet @xgouchet Thanks! Any questions? 13 Presentation template by SlidesCarnival