Coder Social home page Coder Social logo

vipulshah2010 / foodapp Goto Github PK

View Code? Open in Web Editor NEW
30.0 2.0 8.0 7.58 MB

Proof of concept for food app [JetPack + Coroutines + Flow + MockK + JaCoCo coverage + SonarQube]

License: Apache License 2.0

Kotlin 97.54% Java 2.46%
kotlin-android architecture-components constraint-layout room-persistence-library clean-architecture repository-pattern coroutines coroutines-android coroutines-flow mvvm-architecture test-coverage jacoco-reports sonarqube

foodapp's Introduction

FoodApp

License Build Status

FoodApp is a small playground application built using MVVM architecture.
This project is primarily built with purpose of trying out new android tech stack.
It showcase Usecase and Repository architecture pattern for loading data from network and persisting it in database.


Library and Frameworks

  • Minimum SDK level 21
  • Kotlin based, Coroutines + Flow for asynchronous.
  • Dagger-Hilt (alpha) for dependency injection.
  • JetPack
    • LiveData - notify domain layer data to views.
    • Lifecycle - dispose of observing data when lifecycle state changes.
    • ViewModel - UI related data holder, lifecycle aware.
    • Room Persistence - construct a database using the abstract layer.
  • Architecture
    • MVVM Architecture (View - DataBinding - ViewModel - Model)
    • Repository pattern
  • Retrofit2 & OkHttp3 - construct the REST APIs and paging network data.
  • Retrofit - A type-safe HTTP client for Android and Java.
  • Gson - JSON library for Kotlin and Java.
  • coil
  • Material-Components - Material design components like ripple animation, cardView.

Code Coverage and Reporting

  • This project uses Jacoco configuration to measure code coverage and currently the most widely used.
  • SonarQube is used for inspecting the Code Quality and Security codebase.
  • SonarQube consumes Jacoco test coverage report and displays it on sonarcloud

Run following command from root folder to generate JaCoco reports and view test coverage on sonarcloud

./gradlew clean jacocoTestDebugUnitTestReport sonarqube

Planned workflow:

  • More unit test coverage
  • Instrumentation test coverage
  • Fix Shared element transition

Architecture

FoodApp is based on MVVM architecture and a repository pattern.

Find this repository useful? ❤️

follow me on twitter! 🤩

License

Designed and developed by 2020 vipulshah2010 (Vipul Shah)

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

foodapp's People

Contributors

vipulshah2010 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.