![](https://androidpro.io/wp-content/uploads/2023/06/EA6E91FD-2D68-48A6-8609-9F7B5109FB91-1024x1024.png)
masterclass recording
learn how to effectively write unit tests in Kotlin
![](https://androidpro.io/wp-content/uploads/2023/06/Projekt-bez-nazwy-2.png)
Jarosław Michalik
About the instructor
Google Developer Expert in Kotlin, conference speaker & educator.
![](https://androidpro.io/wp-content/uploads/2023/06/EA6E91FD-2D68-48A6-8609-9F7B5109FB91-1024x1024.png)
Agenda
Writing Unit Tests for Coroutines
- Introduction to unit testing
- Writing unit tests for Coroutines with jUnit
- Common pitfalls and how to avoid them
Introduction to Kotest and MockK
- An introduction to Kotest and MockK libraries
- Setup and configuration
- Basic examples
Testing Coroutines with Kotest and MockK
- How to use Kotest and MockK for Coroutine testing
- Hands-on exercises
- Tips for effective testing
Testing StateFlow for Android
- How to structure tests in ViewModel
- ViewRobot pattern
- Tips for writing unit tests on Android
![](https://androidpro.io/wp-content/uploads/2023/06/213d5eb4e224b12a0a16f363050fc623171bc7d9-1024x628.webp)
You get…
- Instant unlimited access to masterclass recording
- Instant access to repository and supporting materials
- You’ll be first to know about upcoming workshops and masterclasses
Students Testimonials
![](https://androidpro.io/wp-content/uploads/2023/06/testimonial_person_icon-1.png)
“Code examples helped me understand mocking mechanisms. Jaroslaw explained every step toroughly.”
Chris P.
Android Developer
![](https://androidpro.io/wp-content/uploads/2023/06/testimonial_person_icon-1.png)
“In short period of time, the class taught straight forward way to test Kotlin code.“
Dhaval S.
Android Developer
![](https://androidpro.io/wp-content/uploads/2023/06/testimonial_person_icon-1.png)
“Your best workshop about testing so far. Thank you!”
Ewa R,
Android Developer
Take your unit testing skills to the next level.