Cobertura -Maven Code Coverage Report

Cobertura -Maven Code Coverage Report

As we all are aware of generating and understanding the code coverage is one of the most important aspects in any project either be development or testing.

So for generating the complete code coverage report of our project we are going to use the Maven Cobertura plugin.

Cobertura is an open-source reporting tool that gives us the complete test coverage of the code in our project.

To know more about this. Please refer to this link.

To configure Maven Cobertura plugin inside our project, we need to put the below plugin into reporting section of our POM.xml file.

Once this is done we need to execute mvn cobertura:cobertura from the command prompt

This will generate a report in target/site/cobertura in our project directory.

The generated report will give us clear coverage in terms of no of lines of code, Branch coverage, complexity.



My Name is Ankur Jain and I am currently working as Automation Test Architect.I am ISTQB Certified Test Manager,Certified UI Path RPA Developer as well as Certified Scrum Master with total 12 years of working experience with lot of big banking clients around the globe.I love to Design Automation Testing Frameworks with Selenium,Appium,Protractor,Cucumber,Rest-Assured, Katalon Studio and currently exploring lot in Dev-OPS as well. I am currently staying in Mumbai, Maharashtra. Please Connect with me through Contact Us page of this website.

Previous Post
Next Post