An open API service indexing awesome lists of open source software.

https://github.com/philippeboisney/retrokotlin

Simple Android app to show how unit testing with MockWebServer and Architecture Components (ViewModel + LiveData)
https://github.com/philippeboisney/retrokotlin

android architecture-components dagger2 kotlin kotlin-android livedata mockwebserver retrofit2 rxjava2 viewmodel

Last synced: 2 months ago
JSON representation

Simple Android app to show how unit testing with MockWebServer and Architecture Components (ViewModel + LiveData)

Awesome Lists containing this project

README

          

# RetroKotlin
This is an Android demo application to show how to better **unit testing** when using Architecture Components (ViewModel, LiveData & RxJava)

You can find the related article on my Medium : https://medium.com/@Phil_Boisney/how-to-better-unit-testing-42a956e005d6

## PRESENTATION
This simple app is composed of a single screen. When this screen appears, we will fetch (Retrofit) the Github information of Jake Wharton.

## PREVIEW



### Architecture Components
This application implements the following concepts :
- ViewModel
- LiveData
- RxJava 2
- Dagger 2
- MockWebServer

### Libraries
* [Android Support Library][support-lib]
* [Android Architecture Components][arch]
* [Dagger 2][dagger2] for dependency injection
* [RxJava 2][rxjava2] for composing asynchronous and event-based programs using observable sequences
* [Retrofit][retrofit] for REST api communication
* [Glide][glide] for image loading
* [MockWebServer][mockwebserver] for testing HTTP clients

[support-lib]: https://developer.android.com/topic/libraries/support-library/index.html
[arch]: https://developer.android.com/arch
[dagger2]: https://google.github.io/dagger
[retrofit]: http://square.github.io/retrofit
[glide]: https://github.com/bumptech/glide
[mockwebserver]: https://github.com/square/okhttp/tree/master/mockwebserver
[rxjava2]: https://github.com/ReactiveX/RxJava