| Auszug |
|---|
|
Nuclos JaCoCo: code coverage, offline weaving, jacoco-maven-plugin, jacoco.exec, coverage profile, mvn verify, AspectJ. |
Language: Deutsch · English
Code coverage (JaCoCo)
Code coverage with JaCoCo – offline weaving, coverage profile and report generation.
| Status |
|---|
| colour | Green |
|---|
| title | Updated: Jul 2026 |
|---|
|
| Status |
|---|
| colour | Grey |
|---|
| title | applies to Nuclos 4.2026.x |
|---|
|
Code coverage of the Nuclos build and the integration tests is measured with JaCoCo (from v4.2024.13).
Process
- Offline weaving via the
jacoco-maven-plugin after javac but before the AspectJ bytecode manipulation (runtime online weaving did not work for Nuclos due to AspectJ/Spring weaving). - Include the JaCoCo runtime as a dependency in all Maven modules.
- Unit and integration tests write all coverage data to
$NUCLOS_GIT_ROOT/target/jacoco.exec.
Invocation
Activation via the Maven profile coverage, e.g. for the Tomcat server integration tests:
| Codeblock |
|---|
|
mvn clean verify -Dlocale=de_DE -Dtest.webclient.skip=true -P coverage,test,test-tomcat |
Create a report per module:
| Codeblock |
|---|
|
mvn jacoco:report@coverage-report |
Related pages
Sonar code analysis
Sonar.
Open →
Unit tests with TestNG or JUnit and Spring support
Unit tests.
Open →