Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Measure Coverage with JaCoCo #2

Closed
arobirosa opened this issue Apr 4, 2020 · 5 comments · Fixed by #26
Closed

Measure Coverage with JaCoCo #2

arobirosa opened this issue Apr 4, 2020 · 5 comments · Fixed by #26
Assignees
Labels
good first issue Good for newcomers in-progress In progress priorityNormal Reduction of the functionality of the extension task Non-developement task
Milestone

Comments

@arobirosa
Copy link
Owner

arobirosa commented Apr 4, 2020

Latest commit of current deployed version: 37cf3dc

Steps to reproduce:

  • Checkout repository
  • Run ant clean all yunitinit qa

Expected Result

ca. 75% Coverage

Actual Result

100% coverage and no classes are shown

Log Entries: None

@arobirosa arobirosa added bug Something isn't working priorityNormal Reduction of the functionality of the extension labels Apr 4, 2020
@arobirosa
Copy link
Owner Author

Cobertura isn't compatible with Java 11 because it uses ASM 5. The project is abandoned. I will migrate the coverage analysis to JaCoCo which is compatible with Java 11 and used by SonarCube.

@arobirosa arobirosa changed the title Cobertura shows 100% coverage Measure Coverage with JaCoCo Apr 11, 2020
@arobirosa arobirosa added task Non-developement task and removed bug Something isn't working labels Apr 11, 2020
@arobirosa arobirosa added this to the 1.5.4 milestone Feb 8, 2023
@arobirosa arobirosa added the good first issue Good for newcomers label Feb 8, 2023
@arobirosa arobirosa self-assigned this Feb 9, 2023
@arobirosa arobirosa added the in-progress In progress label Feb 9, 2023
@arobirosa
Copy link
Owner Author

Sonarcloud don't have a free plan for open-source projects and I don't have a server to host a sonarqube.

@fibsifan
Copy link

fibsifan commented Feb 9, 2023

Hi Antonio,

I use a free Sonarcloud account for a project on gitlab, I think it is still possible to register your project as open source.

As for analyzing sap commerce extensions with Jacoco: that seems to be a bit tricky, but not impossible. Do you use GitHub actions to run tests on pull requests?

@arobirosa
Copy link
Owner Author

Hi @fibsifan ,

I just created a free account in sonarcloud and I will try to try the tests and get the metrics from this project there.

Thanks a lot, Johannes!

@arobirosa arobirosa linked a pull request Feb 14, 2023 that will close this issue
@arobirosa
Copy link
Owner Author

Now the ant target qa checks the test line coverage with JaCoCo. If an unit or integration tests fails or the line coverage is lower than 75%, the build fails.

In the ticket #10 I will integrate sonarqube and adapt the ant target qa to send the coverage information to sonar.

I close this ticket.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers in-progress In progress priorityNormal Reduction of the functionality of the extension task Non-developement task
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants