Skip to content

A sample project to demonstrate the process of using Dagger in Unit testing

Notifications You must be signed in to change notification settings

prokash-sarkar/DaggerUnitTest

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Dagger Unit Test Sample

Specs

API

Overview

If you have Dagger in your project but never used it for testing, it’s high time to give it a try. Dagger makes your code so much easier to test. Once the test setup is complete, all you have to do is plug and play with the dependencies. Also, dependency injection is a crucial concept in testing, and you should use it whenever possible.

Article Link

To read the full article, please check here.

Architecture

The App uses MVVM design pattern along with a Data Repository.

Project Details

The sample app has only one screen that searches through Github repo by a keyword. The app fetches the API response through a Data Repository and outputs the result inside a ViewModel. Finally, an Activity watches for LiveData changes and sets the output inside a TextView.

3rd Party Libraries

The app uses the following 3rd party libraries:

About

A sample project to demonstrate the process of using Dagger in Unit testing

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages