Skip to content

Andorid App utilizing Gousto API to showcase Clean architecture (MVVM + Kotlin + Retrofit2 + Hilt + Coroutines + Kotlin Flow + mockK + Espresso + Junit + Unit Tests)

usamayasin/GoustoAndroidTask

Repository files navigation

GoustoApp

An simple GoustoApp utilizing Gousto Products API for showing products lists.

Built with ❤︎ by Muhammad Usama Yasin

Features

  • Home Screen showing list of products
  • Offline Support.
  • Detail Screen to show more information about a product.

Architecture

  • Built with Modern Android Development practices.
  • Utilized Usecase, Repository pattern for data.
  • Includes valid Unit tests for Repository and Usecases.

Built With 🛠

  • Kotlin - First class and official programming language for Android development.
  • Coroutines - For asynchronous and more..
  • Flow - A cold asynchronous data stream that sequentially emits values and completes normally or with an exception.
  • Android Architecture Components - Collection of libraries that help you design robust, testable, and maintainable apps.
    • LiveData - Data objects that notify views when the underlying data changes.
    • ViewModel - Stores UI-related data that isn't destroyed on UI changes.
    • ViewBinding - Generates a binding class for each XML layout file present in that module and allows you to more easily write code that interacts with views.
  • Dependency Injection
    • Hilt - Easier way to incorporate Dagger DI into Android apps.
  • Room - For saving Data in local DB and to provide offline support.
  • Material Components for Android - Modular and customizable Material Design UI components for Android.
  • Gradle Kotlin DSL - For writing Gradle build scripts using Kotlin.
  • MockK - For Mocking and Unit Testing.
  • Espresso - Espresso to write concise, beautiful, and reliable Android UI tests.
  • Glide - Glide is a fast and efficient open source media management and image loading framework for Android.

Observations:

  • API does not support Pagination. No params to utilize for pagination with API. But as a work-around ,we can save all the data in our LocalDatabase and then implement pagination on the room to fetch records form the localDatabase. But it will take more time to do. So, I left it as an improvement.

Improvements:

  • Multi Module
  • Add more Unit/UI Tests
  • Build UI with Compose

👨 Developed By

Muhammad Usama Yasin

Linkedin

Releases

No releases published

Packages

No packages published

Languages