Home | History | Annotate | Download | only in org.jacoco.doc
      1 <?xml version="1.0" encoding="UTF-8"?>
      2 <!--
      3    Copyright (c) 2009, 2018 Mountainminds GmbH & Co. KG and Contributors
      4    All rights reserved. This program and the accompanying materials
      5    are made available under the terms of the Eclipse Public License v1.0
      6    which accompanies this distribution, and is available at
      7    http://www.eclipse.org/legal/epl-v10.html
      8 
      9    Contributors:
     10       Evgeny Mandrikov - initial API and implementation
     11 -->
     12 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
     13   <modelVersion>4.0.0</modelVersion>
     14 
     15   <parent>
     16     <groupId>org.jacoco</groupId>
     17     <artifactId>org.jacoco.build</artifactId>
     18     <version>0.8.0</version>
     19     <relativePath>../org.jacoco.build</relativePath>
     20   </parent>
     21 
     22   <artifactId>org.jacoco.doc</artifactId>
     23   <!-- do not set packaging to pom, because otherwise we will receive "Not executing Javadoc as the project is not a Java classpath-capable package" -->
     24 
     25   <name>JaCoCo :: Documentation</name>
     26   <description>JaCoCo Documentation</description>
     27 
     28   <properties>
     29     <maven.deploy.skip>true</maven.deploy.skip>
     30   </properties>
     31 
     32   <dependencies>
     33     <dependency>
     34       <groupId>${project.groupId}</groupId>
     35       <artifactId>org.jacoco.core</artifactId>
     36     </dependency>
     37     <dependency>
     38       <groupId>${project.groupId}</groupId>
     39       <artifactId>org.jacoco.core.test</artifactId>
     40       <version>${project.version}</version>
     41       <scope>test</scope>
     42     </dependency>
     43     <dependency>
     44       <groupId>${project.groupId}</groupId>
     45       <artifactId>org.jacoco.report</artifactId>
     46     </dependency>
     47     <dependency>
     48       <groupId>${project.groupId}</groupId>
     49       <artifactId>org.jacoco.report.test</artifactId>
     50       <version>${project.version}</version>
     51       <scope>test</scope>
     52     </dependency>
     53     <dependency>
     54       <groupId>${project.groupId}</groupId>
     55       <artifactId>org.jacoco.agent</artifactId>
     56     </dependency>
     57     <dependency>
     58       <groupId>${project.groupId}</groupId>
     59       <artifactId>org.jacoco.agent.test</artifactId>
     60       <version>${project.version}</version>
     61       <scope>test</scope>
     62     </dependency>
     63     <dependency>
     64       <groupId>${project.groupId}</groupId>
     65       <artifactId>org.jacoco.agent.rt</artifactId>
     66     </dependency>
     67     <dependency>
     68       <groupId>${project.groupId}</groupId>
     69       <artifactId>org.jacoco.agent.rt.test</artifactId>
     70       <version>${project.version}</version>
     71       <scope>test</scope>
     72     </dependency>
     73     <dependency>
     74       <groupId>${project.groupId}</groupId>
     75       <artifactId>org.jacoco.ant</artifactId>
     76     </dependency>
     77     <dependency>
     78       <groupId>${project.groupId}</groupId>
     79       <artifactId>org.jacoco.ant.test</artifactId>
     80       <version>${project.version}</version>
     81       <scope>test</scope>
     82     </dependency>
     83     <dependency>
     84       <groupId>${project.groupId}</groupId>
     85       <artifactId>org.jacoco.cli</artifactId>
     86     </dependency>
     87     <dependency>
     88       <groupId>${project.groupId}</groupId>
     89       <artifactId>org.jacoco.cli.test</artifactId>
     90       <version>${project.version}</version>
     91       <scope>test</scope>
     92     </dependency>
     93     <dependency>
     94       <groupId>${project.groupId}</groupId>
     95       <artifactId>org.jacoco.examples</artifactId>
     96       <version>${project.version}</version>
     97     </dependency>
     98     <dependency>
     99       <groupId>${project.groupId}</groupId>
    100       <artifactId>org.jacoco.examples.test</artifactId>
    101       <version>${project.version}</version>
    102       <scope>test</scope>
    103     </dependency>
    104     <dependency>
    105       <groupId>${project.groupId}</groupId>
    106       <artifactId>jacoco-maven-plugin</artifactId>
    107       <version>${project.version}</version>
    108     </dependency>
    109     <dependency>
    110       <groupId>${project.groupId}</groupId>
    111       <artifactId>jacoco-maven-plugin.test</artifactId>
    112       <version>${project.version}</version>
    113       <scope>test</scope>
    114     </dependency>
    115   </dependencies>
    116 
    117   <build>
    118     <sourceDirectory>src</sourceDirectory>
    119 
    120     <plugins>
    121       <plugin>
    122         <groupId>org.jacoco</groupId>
    123         <artifactId>jacoco-maven-plugin</artifactId>
    124         <version>${project.version}</version>
    125         <executions>
    126           <execution>
    127             <id>report-aggregate</id>
    128             <phase>prepare-package</phase>
    129             <goals>
    130               <goal>report-aggregate</goal>
    131             </goals>
    132             <configuration>
    133               <title>JaCoCo</title>
    134               <footer>Code Coverage Report for JaCoCo ${project.version}</footer>
    135               <includes>
    136                 <!-- Analyze class files only to exclude shaded agent JAR from report -->
    137                 <include>**/*.class</include>
    138               </includes>
    139               <excludes>
    140                 <exclude>**/HelpMojo.class</exclude>
    141               </excludes>
    142             </configuration>
    143           </execution>
    144         </executions>
    145       </plugin>
    146 
    147       <plugin>
    148         <groupId>org.apache.maven.plugins</groupId>
    149         <artifactId>maven-antrun-plugin</artifactId>
    150         <executions>
    151           <execution>
    152             <id>prepare-reports</id>
    153             <phase>prepare-package</phase>
    154             <goals>
    155               <goal>run</goal>
    156             </goals>
    157             <configuration>
    158               <target>
    159                 <echo message="JUnit report"/>
    160                 <mkdir dir="${project.build.directory}/junit"/>
    161                 <junitreport todir="${project.build.directory}/junit">
    162                   <fileset dir="../org.jacoco.agent.test/target" includes="surefire-reports/**/*.xml"/>
    163                   <fileset dir="../org.jacoco.agent.rt.test/target" includes="surefire-reports/**/*.xml"/>
    164                   <fileset dir="../org.jacoco.ant.test/target" includes="surefire-reports/**/*.xml"/>
    165                   <fileset dir="../org.jacoco.cli.test/target" includes="surefire-reports/**/*.xml"/>
    166                   <fileset dir="../org.jacoco.core.test/target" includes="surefire-reports/**/*.xml"/>
    167                   <fileset dir="../org.jacoco.report.test/target" includes="surefire-reports/**/*.xml"/>
    168                   <fileset dir="../org.jacoco.examples.test/target" includes="surefire-reports/**/*.xml"/>
    169                   <report format="noframes" styledir="xsl" todir="${project.build.directory}/junit">
    170                     <param name="qualified.bundle.version" expression="${qualified.bundle.version}"/>
    171                     <param name="jacoco.home.url" expression="${jacoco.home.url}"/>
    172                     <param name="copyright.years" expression="${copyright.years}"/>
    173                   </report>
    174                 </junitreport>
    175                 <move file="${project.build.directory}/junit/junit-noframes.html" tofile="${project.build.directory}/junit/index.html"/>
    176               </target>
    177             </configuration>
    178           </execution>
    179         </executions>
    180         <dependencies>
    181           <dependency>
    182             <groupId>org.apache.ant</groupId>
    183             <artifactId>ant-junit</artifactId>
    184             <version>1.8.2</version>
    185           </dependency>
    186         </dependencies>
    187       </plugin>
    188 
    189       <plugin>
    190         <groupId>org.apache.maven.plugins</groupId>
    191         <artifactId>maven-javadoc-plugin</artifactId>
    192         <executions>
    193           <execution>
    194             <id>attach-javadocs</id>
    195             <phase>prepare-package</phase>
    196             <goals>
    197               <goal>jar</goal>
    198             </goals>
    199             <configuration>
    200               <reportOutputDirectory>${project.build.directory}/apidocs</reportOutputDirectory>
    201               <includeDependencySources>true</includeDependencySources>
    202               <excludePackageNames>*.internal,org.jacoco.ant,org.jacoco.maven,org.jacoco.examples</excludePackageNames>
    203               <dependencySourceIncludes>
    204                 <dependencySourceInclude>org.jacoco:*</dependencySourceInclude>
    205               </dependencySourceIncludes>
    206               <dependencySourceExcludes>
    207                 <dependencySourceExclude>org.jacoco:*.test</dependencySourceExclude>
    208               </dependencySourceExcludes>
    209               <doctitle>JaCoCo ${qualified.bundle.version} API</doctitle>
    210               <windowtitle>JaCoCo ${qualified.bundle.version} API</windowtitle>
    211               <use>true</use>
    212               <version>false</version>
    213               <groups>
    214                 <!-- Note: using org.jacoco.core.* for packages would omit the org.jacoco.core package but using org.jacoco* will include it. -->
    215                 <group>
    216                   <title>Bundle org.jacoco.core</title>
    217                   <packages>org.jacoco.core*</packages>
    218                 </group>
    219                 <group>
    220                   <title>Bundle org.jacoco.report</title>
    221                   <packages>org.jacoco.report*</packages>
    222                 </group>
    223                 <group>
    224                   <title>Bundle org.jacoco.agent</title>
    225                   <packages>org.jacoco.agent*</packages>
    226                 </group>
    227                 <group>
    228                   <title>JaCoCo Runtime</title>
    229                   <packages>org.jacoco.agent.rt:com.vladium.emma.rt</packages>
    230                 </group>
    231               </groups>
    232               <overview>javadoc/overview.html</overview>
    233               <stylesheetfile>javadoc/stylesheet.css</stylesheetfile>
    234             </configuration>
    235           </execution>
    236         </executions>
    237       </plugin>
    238 
    239       <plugin>
    240         <groupId>org.codehaus.mojo</groupId>
    241         <artifactId>xml-maven-plugin</artifactId>
    242         <executions>
    243           <execution>
    244             <id>transform-generated-doc</id>
    245             <goals>
    246               <goal>transform</goal>
    247             </goals>
    248             <configuration>
    249               <transformationSets>
    250                 <transformationSet>
    251                   <dir>../jacoco-maven-plugin/target/generated-site/xdoc</dir>
    252                   <includes>
    253                     <include>*.xml</include>
    254                   </includes>
    255                   <stylesheet>xsl/maven-goal.xsl</stylesheet>
    256                   <fileMappers>
    257                     <fileMapper implementation="org.codehaus.plexus.components.io.filemappers.FileExtensionMapper">
    258                       <targetExtension>.html</targetExtension>
    259                     </fileMapper>
    260                   </fileMappers>
    261                   <parameters>
    262                     <parameter>
    263                       <name>qualified.bundle.version</name>
    264                       <value>${qualified.bundle.version}</value>
    265                     </parameter>
    266                     <parameter>
    267                       <name>jacoco.home.url</name>
    268                       <value>${jacoco.home.url}</value>
    269                     </parameter>
    270                     <parameter>
    271                       <name>copyright.years</name>
    272                       <value>${copyright.years}</value>
    273                     </parameter>
    274                   </parameters>
    275                 </transformationSet>
    276                 <transformationSet>
    277                   <dir>../org.jacoco.cli/target/generated-documentation</dir>
    278                   <includes>
    279                     <include>*.xml</include>
    280                   </includes>
    281                   <stylesheet>xsl/cli.xsl</stylesheet>
    282                   <fileMappers>
    283                     <fileMapper implementation="org.codehaus.plexus.components.io.filemappers.FileExtensionMapper">
    284                       <targetExtension>.html</targetExtension>
    285                     </fileMapper>
    286                   </fileMappers>
    287                   <parameters>
    288                     <parameter>
    289                       <name>qualified.bundle.version</name>
    290                       <value>${qualified.bundle.version}</value>
    291                     </parameter>
    292                     <parameter>
    293                       <name>jacoco.home.url</name>
    294                       <value>${jacoco.home.url}</value>
    295                     </parameter>
    296                     <parameter>
    297                       <name>copyright.years</name>
    298                       <value>${copyright.years}</value>
    299                     </parameter>
    300                   </parameters>
    301                 </transformationSet>
    302               </transformationSets>
    303             </configuration>
    304           </execution>
    305           <execution>
    306             <id>default-validate</id>
    307             <goals>
    308               <goal>validate</goal>
    309             </goals>
    310             <configuration>
    311               <validationSets>
    312                 <validationSet>
    313                   <dir>.</dir>
    314                   <includes>
    315                     <include>docroot/**/*.html</include>
    316                     <include>target/generated-resources/xml/xslt/*.html</include>
    317                   </includes>
    318                 </validationSet>
    319               </validationSets>
    320             </configuration>
    321           </execution>
    322         </executions>
    323       </plugin>
    324     </plugins>
    325   </build>
    326 </project>
    327