@@ -35,9 +35,9 @@ Offical page of the project is on:
35352. Requirements
3636---------------
3737
38- * Latest Java (At least 1.7, 1.8 is supported )
38+ * Latest Java (At least 1.8 )
3939 http://www.oracle.com/technetwork/java/
40- * A servlet container like Tomcat (7 .x or later)
40+ * A servlet container like Tomcat (8 .x or later)
4141 supporting Servlet 2.4 and JSP 2.0
4242 http://tomcat.apache.org/
4343 * Exuberant Ctags
@@ -439,7 +439,7 @@ Solaris 11:
439439
440440Debian/Ubuntu:
441441
442- # apt-get install sun-java6 -javadb
442+ # apt-get install sun-java8 -javadb
443443
444444Other:
445445
@@ -638,13 +638,8 @@ being executed on) under the dist/ directory.
638638Note: For full coverage report your system has to provide proper junit test
639639environment, that would mean:
640640
641- - you have to use Ant 1.7 and above
642- - at least junit-4.10.jar has to be in ant's classpath (e.g. in ./lib)
643- - Example install in the top of the opengrok repository:
644-
645- $ cd lib
646- $ wget http://.../junit-4.10.jar
647- $ jar -xf junit-4.10.jar
641+ - you have to use Ant 1.9 and above
642+ - at least junit-4.12.jar has to be in ant's classpath (e.g. in ./lib)
648643
649644 - install derby.jar to ant's classpath so that Java DB tests can be run
650645 - your PATH must contain directory with exuberant ctags binary
@@ -696,53 +691,18 @@ under the lib directory):
696691There is also a findbugs-xml ant target that can be used to generate XML files
697692that can later be parsed, e.g. by Jenkins.
698693
699- 9.3 Using Emma
694+ 9.3 Using Jacoco
700695--------------
701696
702- If you want to check test coverage on OpenGrok, download Emma from
703- http://emma.sourceforge.net/. Place emma.jar and emma-ant.jar in the
704- opengrok/trunk/lib directory, or ~/.ant/lib.
705-
706- Now you can instrument your classes, and create a jar file:
707-
708- $ ant emma-instrument
709-
710- If you are using NetBeans, select File - "opengrok" Properties
711- - libraries - Compile tab. Press the "Add JAR/Folder" and select
712- lib/emma.jar and lib/emma_ant.jar
713-
714- If you are not using netbeans, you have to edit the file
715- nbproject/project.properties, and add "lib/emma.jar" and
716- "lib/emma_ant.jar" to the javac.classpath inside it.
717-
718- Now you can put the classes into jars and generate distributable:
719-
720- $ ant dist
721-
722- The classes inside opengrok.jar should now be instrumented.
723- If you use opengrok.jar for your own set of tests, you need
724- emma.jar in the classpath.If you want to specify where to store
725- the run time analysis, use these properties:
726-
727- emma.coverage.out.file=path/coverage.ec
728- emma.coverage.out.merge=true
729-
730- The coverage.ec file should be placed in the opengrok/trunk/coverage
731- directory for easy analyze.
732-
733- If you want to test the coverage of the unit tests, you can
734- run the tests:
735-
736- $ ant test
737-
738- Alternatively press Alt+F6 in NetBeans to achieve the same.
697+ If you want to check test coverage on OpenGrok, download jacoco from
698+ http://www.eclemma.org/jacoco/. Place jacocoagent.jar and jacocoant.jar in the
699+ opengrok/lib ~/.ant/lib or into classpath (-lib option of ant).
739700
740- Now you should get some output saying that Emma is placing runtime
741- coverage data into coverage.ec.
701+ Now you can instrument your classes and test them run:
742702
743- To generate reports, run ant again:
703+ $ ant -Djacoco=true -Djacoco.home=/<path_to>/jacoco jacoco-code-coverage
744704
745- $ ant emma-report
705+ Now you should get output data in .
746706
747707Look at coverage/coverage.txt, coverage/coverage.xml and
748708coverage/coverage.html to see how complete your tests are.
@@ -857,6 +817,7 @@ e.g. using bash:
8578179.8 Using Travis CI
858818-------------------
859819
820+ Travis depends on updated and working maven build.
860821Please see .travis.yml, if your branch has this file,
861822you should be able to connect your Github to Travis CI.
862823OpenGroks Travis is here: https://travis-ci.org/OpenGrok/OpenGrok
0 commit comments