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
MockK and Truth - Unit Tests - Android
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Moro
January 03, 2022
Programming
150
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
MockK and Truth - Unit Tests - Android
First contact with the libraries: MockK and Truth.
Moro
January 03, 2022
More Decks by Moro
See All by Moro
More Accessible Apps - Android
gabrielbmoro
0
12
Variables and Tips - Android
gabrielbmoro
0
12
Migrating an Existing App to Compose - Android
gabrielbmoro
0
15
Recycler View and Performance - Android
gabrielbmoro
0
14
Repository Pattern and Productivity - Android
gabrielbmoro
0
16
What is new in Android Jetpack?
gabrielbmoro
0
21
List Users - Android
gabrielbmoro
0
6
Working with Collections - Kotlin
gabrielbmoro
0
18
Dependency Inversion - Example
gabrielbmoro
0
15
Other Decks in Programming
See All in Programming
Inside Stream API
skrb
1
700
Developing with AI Agents — Codex, Claude Code & Cowork Practical Guide
x5gtrn
PRO
0
1.3k
Webフレームワークの ベンチマークについて
yusukebe
0
160
さぁV100、メモリをお食べ・・・
nilpe
0
140
タクシーアプリ『GO』の バックエンド開発のおける AI利活用と若者のすべて
pyama86
3
2k
気圧・高度・GPSを記録&可視化するアプリ「Koudo」を作った話
hjmkth
1
200
AIで効率化できた業務・日常
ochtum
0
130
AIチームを指揮するOSS「TAKT」活用術 / How to Use “TAKT,” an OSS Tool for Orchestrating AI Teams
nrslib
6
890
CSC307 Lecture 17
javiergs
PRO
0
320
AI時代の仕事技芸論 — ソフトウェア開発で「遊ぶように働く」職人的熟達のすすめ
kuranuki
2
670
Java × distroless で 軽量なコンテナイメージを / Java on Distroless
contour_gara
0
540
Composerを使ったサプライチェーン攻撃の様子を眺めてみる #phpstudy
o0h
PRO
2
250
Featured
See All Featured
30 Presentation Tips
portentint
PRO
1
320
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
160
Test your architecture with Archunit
thirion
1
2.3k
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
580
Mind Mapping
helmedeiros
PRO
1
250
Information Architects: The Missing Link in Design Systems
soysaucechin
0
970
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
1.1k
Making Projects Easy
brettharned
120
6.7k
Game over? The fight for quality and originality in the time of robots
wayneb77
1
200
Skip the Path - Find Your Career Trail
mkilby
1
150
The Illustrated Guide to Node.js - THAT Conference 2024
reverentgeek
1
380
ラッコキーワード サービス紹介資料
rakko
1
3.6M
Transcript
Mockk & Truth Your Unit Tests better for reading By
Moro
MockK It is a powerful mocking library for Kotlin It
is a library to help us write more fluent assertions for Android. Truth
Example In this case, the MainViewModel has the responsibility for
defining the first destination, where the app starts. Has email stored? Dashboard Screen Welcome Screen Yes No
MainViewModel
MainViewModel Dependency
Mocking the Dependency
Mocking the Dependency
MainViewModel Test - Case #1 Has email stored? Dashboard Screen
Yes
MainViewModel Test - Case #2 Has email stored? Welcome Screen
No
None