Рет қаралды 7,312
Learn Android Unit Testing - Learn how to unit test repository in Android MVVM Architecture. Learn how to use Mockito to mock different objects and define behavior using Mockito.when. Mocking objects help define canned responses for your functions. You can have pre-defined behavior for your methods that can help to write unit tests that are isolated from its collaborators. Learn how to define unit test cases for repository with different API responses.
Learn how to share code between test and androidtest directory in android using sourcesets in build.gradle file. Defining a common location that is accessible from both test directory can help share the code.
In this tutorial, we have covered Mockito, JUnit testing in Android. Learn unit testing in Android with simple examples in Kotlin Hindi. Everything is explained in Hindi (हिन्दी)
Topics covered -
1. Complete MVVM Architecture Example Walkthrough
2. Unit Test Case Setup using Mockito Mocking
3. Android Repository Unit Testing Simple Example
4. Sharing code between unit tests and instrumentation tests on android
5. Android JUnit Test Cases
Kotlin Flows Playlist -
• Kotlin Flows Tutorials
Jetpack Paging Tutorial -
• Android Paging 3 | Jet...
Complete Dependency Injection Playlist Link -
• Dagger 2 - Dependency ...
Complete Android Architecture Components Playlist -
• Android Architecture C...
Beginner series in Android Playlist (Hindi) -
• Android Tutorials Step...
Kotlin Beginners Tutorial Series -
• Kotlin Beginner Tutori...
For more info - visit the below link
www.cheezycode.com
We are social. Follow us at -
Facebook - / cheezycode
Twitter - / cheezycode
Instagram - / cheezycode