Browse Source

doc how to get code coverage for unit,integ,combined

Robert Muir 10 years ago
parent
commit
517f00b048
1 changed files with 16 additions and 2 deletions
  1. 16 2
      TESTING.asciidoc

+ 16 - 2
TESTING.asciidoc

@@ -527,13 +527,27 @@ sudo bats $BATS/*.bats
 
 == Coverage analysis
 
-To run tests instrumented with jacoco and produce a coverage report in
-`target/site/jacoco/`:
+Tests can be run instrumented with jacoco to produce a coverage report in
+`target/site/jacoco/`.
+
+Unit test coverage:
 
 ---------------------------------------------------------------------------
 mvn -Dtests.coverage test jacoco:report
 ---------------------------------------------------------------------------
 
+Integration test coverage:
+
+---------------------------------------------------------------------------
+mvn -Dtests.coverage -Dskip.unit.tests verify jacoco:report
+---------------------------------------------------------------------------
+
+Combined (Unit+Integration) coverage:
+
+---------------------------------------------------------------------------
+mvn -Dtests.coverage verify jacoco:report
+---------------------------------------------------------------------------
+
 == Debugging from an IDE
 
 If you want to run elasticsearch from your IDE, you should execute ./run.sh