{"id":16430640,"url":"https://github.com/praveengnair/jacoco-multi-module-sample","last_synced_at":"2025-10-26T23:31:44.759Z","repository":{"id":43185246,"uuid":"266323379","full_name":"PraveenGNair/jacoco-multi-module-sample","owner":"PraveenGNair","description":"This is an example of multi modular maven project with jacoco coverage for unit, integration and functional testing and generating a merged final report in jacoco.","archived":false,"fork":false,"pushed_at":"2023-05-06T23:39:03.000Z","size":23,"stargazers_count":4,"open_issues_count":2,"forks_count":12,"subscribers_count":2,"default_branch":"master","last_synced_at":"2023-05-07T00:24:29.253Z","etag":null,"topics":["cucumber","jacoco","jacoco-plugin","java","karate","maven","testing"],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/PraveenGNair.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-05-23T11:34:45.000Z","updated_at":"2023-05-06T23:39:08.000Z","dependencies_parsed_at":"2022-08-31T08:52:20.202Z","dependency_job_id":null,"html_url":"https://github.com/PraveenGNair/jacoco-multi-module-sample","commit_stats":null,"previous_names":[],"tags_count":null,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PraveenGNair%2Fjacoco-multi-module-sample","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PraveenGNair%2Fjacoco-multi-module-sample/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PraveenGNair%2Fjacoco-multi-module-sample/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PraveenGNair%2Fjacoco-multi-module-sample/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PraveenGNair","download_url":"https://codeload.github.com/PraveenGNair/jacoco-multi-module-sample/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":219862091,"owners_count":16555980,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cucumber","jacoco","jacoco-plugin","java","karate","maven","testing"],"created_at":"2024-10-11T08:27:46.644Z","updated_at":"2025-10-26T23:31:44.407Z","avatar_url":"https://github.com/PraveenGNair.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Jacoco coverage for Multi Module Maven Project\n\n## Overview\n\u003eA sample multi-modular maven project demonstrating how to met coverage for unit, integration and/or functional testing withing different modules.\n\u003eThe test results is aggregated by Jacoco plugin and a merged code coverage report is being generated.\n\u003eThe detailed blog and instructions of the project is described in [blog](https://medium.com/@prgnr173/merging-integration-unit-and-functional-test-reports-with-jacoco-de5cde9b56e1).\n\n## Run Command\n\n\u003eJacoco data file location - baseDir / module3 / target / aggregate.exec\n\n\u003eJacoco report location - baseDir / module3 / target / site / jacoco-aggregate / index.html\n\n\n- Unit testing + jacoco reporting. \n_Note: Set a lower Coverage ratio in pom.xml_\n\n`$ mvn clean install`\n\n- Integration testing + jacoco reporting.\n_Note: Set a lower Coverage ratio in pom.xml_\n\n`$ mvn clean install -P integration-test`\n\n-Unit + Integration testing + jacoco merged reporting.\n\n`$ mvn clean install -P testAll`\n  \n _Note: You may add additional configuration for jacoco and control the behaviour. For additional configuration details visit [here.](https://www.eclemma.org/jacoco/trunk/doc/maven.html)_  \n\n# Result: \nThe below test coverage report shows coverage for `testAll` profile. \nThe other important point to consider here is we have tried to increase the coverage of module1 method `concatenation` from module3 by running cucumber tests. Cucumber tests can easily be replaced by any other functional test frameworks like Karate API Testing Framework.\n\n![Coverage Report All](merged-coverage-report-all.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpraveengnair%2Fjacoco-multi-module-sample","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpraveengnair%2Fjacoco-multi-module-sample","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpraveengnair%2Fjacoco-multi-module-sample/lists"}