Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/compscidr/hello-java-android
"Hello Java-Android" with jacoco, junit5, codecov ready to go
https://github.com/compscidr/hello-java-android
android codecov jacoco java junit5
Last synced: 2 days ago
JSON representation
"Hello Java-Android" with jacoco, junit5, codecov ready to go
- Host: GitHub
- URL: https://github.com/compscidr/hello-java-android
- Owner: compscidr
- License: apache-2.0
- Created: 2021-09-09T03:25:35.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2024-10-21T15:26:21.000Z (24 days ago)
- Last Synced: 2024-10-22T02:16:02.849Z (24 days ago)
- Topics: android, codecov, jacoco, java, junit5
- Language: Java
- Homepage:
- Size: 750 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# hello-java-android
[![Build Status](https://github.com/compscidr/hello-java-android/workflows/Gradle%20Build/badge.svg)](https://github.com/compscidr/hello-java-android/actions)
[![codecov](https://codecov.io/gh/compscidr/hello-java-android/branch/main/graph/badge.svg)](https://codecov.io/gh/compscidr/hello-java-android)When starting a new project, I always find getting the tools up and running quickly is a pain, so I
wanted something for java / android which already had everything setup and working.This is a WiP inspired by a similar repo for Kotlin / Android: https://github.com/compscidr/hello-kotlin-android
In order to get instrumented test coverage, I'm using an android emulator container which is linked
to a self-hosted runner container: https://jasonernst.com/posts/2021/08/08/Android-Emulator-with-Github-Actions-on-Linux.The other option is to use macos github hosted runners (emulator needs gpu accel to run in a reasonable time)
but I'm cheap and the macos instances are expensive and use all my actions credits too quickly.This aims to be a starter repo with all of the following tooling setup:
* [Github actions](https://github.com/marketplace/actions/gradle-android)
* [Checkstyle]()
* [Junit5](https://junit.org/junit5/docs/current/user-guide/) (unit + integration tests)
* [Jacoco](https://www.eclemma.org/jacoco/)
* [Codecov](https://codecov.io/)# Code coverage notes:
There are three different reports produced:
- one for debug unit tests (located in `app/build/reports/jacoco/jacocoTestReportDebug`)
- one for release unit tests (located in `app/build/reports/jacoco/jacocoTestReportRelease`)
- one for connected (on device / emulator tests) (located in `app/build/reports/coverage/androidTest/debug`)In order to produce them all, just run:
`./gradlew connectedCheck && ./gradlew jacocoTestReport`