Improve code coverage for aaf cadi modules
[aaf/cadi.git] / pom.xml
1 <!--
2   ============LICENSE_START====================================================
3   * org.onap.aaf
4   * ===========================================================================
5   * Copyright © 2017 AT&T Intellectual Property. All rights reserved.
6   * ===========================================================================
7   * Licensed under the Apache License, Version 2.0 (the "License");
8   * you may not use this file except in compliance with the License.
9   * You may obtain a copy of the License at
10   * 
11    *      http://www.apache.org/licenses/LICENSE-2.0
12   * 
13    * Unless required by applicable law or agreed to in writing, software
14   * distributed under the License is distributed on an "AS IS" BASIS,
15   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16   * See the License for the specific language governing permissions and
17   * limitations under the License.
18   * ============LICENSE_END====================================================
19   *
20   * ECOMP is a trademark and service mark of AT&T Intellectual Property.
21   *
22 -->
23 <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/xsd/maven-4.0.0.xsd">
24         <modelVersion>4.0.0</modelVersion>
25         <groupId>org.onap.aaf.cadi</groupId>
26         <artifactId>parent</artifactId>
27         <name>aaf-cadi</name>
28         <version>1.0.0-SNAPSHOT</version>
29         <inceptionYear>2015-07-20</inceptionYear>       
30         <packaging>pom</packaging>
31         <url>https://github.com/att/AAF</url>
32         <description>CADI</description>
33         <licenses>
34                 <license>
35                 <name>BSD License</name>
36                 <url> </url>
37                 </license>
38         </licenses>
39         <developers>
40                 <developer>
41                 <name>Jonathan Gathman</name>
42                 <email></email>
43         <organization>ATT</organization>
44         <organizationUrl></organizationUrl>
45                 </developer>
46         </developers>
47         
48         <parent>             
49        <groupId>org.onap.oparent</groupId>
50        <artifactId>oparent</artifactId>
51        <version>0.1.1</version>
52     </parent>
53         
54         <properties>
55                 <skipSigning>true</skipSigning>
56                 <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
57                 <project.innoVersion>1.0.0-SNAPSHOT</project.innoVersion>
58                 <project.authClientVersion>1.0.0-SNAPSHOT</project.authClientVersion>
59                 <project.dme2Version>3.1.200</project.dme2Version>
60                                 <!-- version>2.8.5.8</version -->
61                                 <!-- version>2.6.20</version -->
62                                 <!-- version>2.6.29</version -->
63                                 <!-- version>2.8.1</version -->
64                                 <!--  version>2.8.2.5</version -->
65                 <!-- jetty-version>8.1.7.v20120910</jetty-version -->
66                 <!-- jetty-version>7.2.0.v20101020</jetty-version -->
67                 <!-- project.jettyVersion>9.0.3.v20130506</project.jettyVersion -->
68                 <project.cadiVersion>1.0.0-SNAPSHOT</project.cadiVersion>
69                 
70                 <!--  SONAR  -->
71                  <jacoco.version>0.7.7.201606060606</jacoco.version>
72             <sonar-jacoco-listeners.version>3.2</sonar-jacoco-listeners.version>
73             <sonar.core.codeCoveragePlugin>jacoco</sonar.core.codeCoveragePlugin>
74             <!-- Default Sonar configuration -->
75             <sonar.jacoco.reportPath>target/code-coverage/jacoco-ut.exec</sonar.jacoco.reportPath>
76             <sonar.jacoco.itReportPath>target/code-coverage/jacoco-it.exec</sonar.jacoco.itReportPath>
77             <!-- Note: This list should match jacoco-maven-plugin's exclusion list below -->
78             <sonar.exclusions>**/gen/**,**/generated-sources/**,**/yang-gen**,**/pax/**</sonar.exclusions>
79                 <nexusproxy>https://nexus.onap.org</nexusproxy>
80                 <snapshotNexusPath>/content/repositories/snapshots/</snapshotNexusPath>
81                 <releaseNexusPath>/content/repositories/releases/</releaseNexusPath>
82                 <stagingNexusPath>/content/repositories/staging/</stagingNexusPath>
83                 <sitePath>/content/sites/site/org/onap/aaf/cadi/${project.artifactId}/${project.version}</sitePath>
84         </properties>
85         <!-- ============================================================== -->
86         <!-- Define the major contributors and developers of CADI -->
87         <!-- ============================================================== -->
88         <contributors>
89                 <contributor>
90                         <name>Jonathan Gathman</name>
91                         <email></email>
92                         <timezone>CST</timezone>
93                 </contributor>
94         </contributors>
95
96         <dependencies>
97                 <dependency>
98                         <groupId>junit</groupId>
99                         <artifactId>junit</artifactId>
100                         <version>4.10</version>
101                         <scope>test</scope>
102                 </dependency>
103         </dependencies>
104
105         <!-- ============================================================== -->
106         <!-- Define sub-projects (modules) -->
107         <!-- ============================================================== -->
108         <modules>
109                 <module>core</module>
110                 <module>client</module>
111                 <module>aaf</module> 
112                 <module>cass</module>
113                 <!-- module>jetty</module -->
114                 <!-- module>weblogic</module -->
115                 <!-- always build last -->
116                 <!--module>swm</module -->
117         </modules>
118
119         <!-- ============================================================== -->
120         <!-- Define project-wide dependencies -->
121         <!-- ============================================================== -->
122         <dependencyManagement>
123                 <dependencies>
124                 <dependency>
125                         <groupId>org.mockito</groupId>
126                         <artifactId>mockito-all</artifactId>
127                         <version>1.9.5</version>
128                         <scope>test</scope>
129                         </dependency>
130                         <dependency>
131                                 <groupId>org.onap.aaf.authz</groupId>
132                                 <artifactId>authz-client</artifactId>
133                                 <version>${project.authClientVersion}</version>
134                         </dependency>
135
136                         <dependency>
137                                 <groupId>org.onap.aaf.cadi</groupId>
138                                 <artifactId>cadi-core</artifactId>
139                                 <version>${project.version}</version>
140                         </dependency>
141
142                         <dependency>
143                                 <groupId>org.onap.aaf.cadi</groupId>
144                                 <artifactId>cadi-core</artifactId>
145                                 <version>${project.version}</version>
146                                 <classifier>tests</classifier>
147                         </dependency>
148
149                         <dependency>
150                                 <groupId>org.onap.aaf.cadi</groupId>
151                                 <artifactId>cadi-cass</artifactId>
152                                 <version>${project.version}</version>
153                         </dependency>
154
155                         <dependency>
156                                 <groupId>org.onap.aaf.cadi</groupId>
157                                 <artifactId>cadi-aaf</artifactId>
158                                 <version>${project.version}</version>
159                         </dependency> 
160
161                     <dependency>
162                                 <groupId>org.onap.aaf.cadi</groupId>
163                                 <artifactId>cadi-aaf</artifactId>
164                                 <version>${project.version}</version>
165                                 <classifier>full</classifier>
166                         </dependency>
167
168                         <dependency>
169                                 <groupId>org.onap.aaf.cadi</groupId>
170                                 <artifactId>cadi-client</artifactId>
171                                 <version>${project.version}</version>
172                         </dependency>
173
174                         <dependency>
175                                 <groupId>org.onap.aaf.cadi</groupId>
176                                 <artifactId>cadi-tomcat</artifactId>
177                                 <version>${project.version}</version>
178                         </dependency>
179
180                         <dependency>
181                                 <groupId>org.onap.aaf.cadi</groupId>
182                                 <artifactId>cadi-tguard</artifactId>
183                                 <version>${project.version}</version>
184                         </dependency>
185
186                         <dependency>
187                                 <groupId>org.onap.aaf.inno</groupId>
188                                 <artifactId>env</artifactId>
189                                 <version>${project.innoVersion}</version>
190                         </dependency>
191
192                         <dependency>
193                                 <groupId>org.onap.aaf.inno</groupId>
194                                 <artifactId>rosetta</artifactId>
195                                 <version>${project.innoVersion}</version>
196                         </dependency>
197
198                         <dependency>
199                                 <groupId>org.eclipse.jetty</groupId>
200                                 <artifactId>jetty-servlet</artifactId>
201                                 <version>9.0.3.v20130506</version>
202                         </dependency>
203
204                         <dependency>
205                                 <groupId>org.eclipse.jetty</groupId>
206                                 <artifactId>jetty-webapp</artifactId>
207                                 <version>9.0.3.v20130506</version>
208                         </dependency>
209
210                         <dependency>
211                                 <groupId>org.eclipse.jetty.aggregate</groupId>
212                                 <artifactId>jetty-all</artifactId>
213                                 <version>9.0.3.v20130506</version>
214                         </dependency>
215
216                         <dependency>
217                                 <groupId>javax.servlet</groupId>
218                                 <artifactId>servlet-api</artifactId>
219                                 <version>2.5</version>
220                         </dependency>
221
222                         <dependency>
223                                 <groupId>com.att.aft</groupId>
224                                 <artifactId>dme2</artifactId>
225                                 <version>${project.dme2Version}</version>
226                                 <exclusions>
227                                         <exclusion>
228                                                 <groupId>org.slf4j</groupId>
229                                                 <artifactId>slf4j-log4j12</artifactId>
230                                         </exclusion>
231                                         <exclusion>
232                                                 <groupId>log4j</groupId>
233                                                 <artifactId>log4j</artifactId>
234                                         </exclusion>
235                                         <exclusion>
236                                                 <groupId>com.att.javax.servlet</groupId>
237                                                 <artifactId>servlet-api</artifactId>
238                                         </exclusion>
239                                         <exclusion>
240                                                 <groupId>javax.mail</groupId>
241                                                 <artifactId>mail</artifactId>
242                                         </exclusion>
243
244                                 </exclusions>
245                         </dependency>
246
247                         <dependency>
248                                 <groupId>org.slf4j</groupId>
249                                 <artifactId>slf4j-api</artifactId>
250                                 <version>1.7.5</version>
251                         </dependency>
252                 </dependencies>
253         </dependencyManagement>
254
255         <!-- ============================================================== -->
256         <!-- Define common plugins and make them available for all modules -->
257         <!-- ============================================================== -->
258         <build>
259                 <testSourceDirectory>src/test/java</testSourceDirectory>
260                 <plugins>
261
262                                 <plugin>
263                                         <inherited>true</inherited>
264                                         <groupId>org.apache.maven.plugins</groupId>
265                                         <artifactId>maven-compiler-plugin</artifactId>
266                                         <version>2.3.2</version>
267                                         <configuration>
268                                                 <source>1.7</source>
269                                                 <target>1.7</target>
270                                         </configuration>
271                                 </plugin>
272         
273                                 <plugin>
274                                         <groupId>org.apache.maven.plugins</groupId>
275                                         <version>2.4</version>
276                                         <artifactId>maven-jar-plugin</artifactId>
277                                         <configuration>
278                                                 <outputDirectory>target</outputDirectory>
279                                                 <archive>
280                                                         <manifestEntries>
281                                                                 <Sealed>true</Sealed>
282                                                         </manifestEntries>
283                                                 </archive>
284                                         </configuration>
285                                 </plugin>
286                                 
287                                 <plugin>
288                                   <groupId>org.apache.maven.plugins</groupId>
289                                   <artifactId>maven-surefire-plugin</artifactId>
290                                   <version>2.17</version>
291                                   <configuration>
292                                         <skipTests>false</skipTests>
293                                         <includes>
294                                           <include>**/JU*.java</include>
295                                         </includes>
296                                         <excludes>
297                                                 <exclude>**/JU_LocalLur.java</exclude>
298                                                 <!-- <exclude>**/JU_BufferedServletInputStream.java</exclude> -->
299                                                 <!--<exclude>**/JU_Passcode.java</exclude> -->
300                                                 <!--<exclude>**/JU_XReader.java</exclude>  -->
301                                                 <exclude>**/JU_CASS.java</exclude>
302                                                 <exclude>**/JU_PropertyLocator.java</exclude>
303                                                 <exclude>**/JU_PermEval.java</exclude>
304                                                 <exclude>**/JU_JMeter.java</exclude>
305                                                 <exclude>**/JU_Lur2_0Call.java</exclude>
306                                         </excludes>   
307                                   </configuration>
308                                 </plugin>
309
310                                 <plugin>
311                                         <groupId>org.apache.maven.plugins</groupId>
312                                         <artifactId>maven-jarsigner-plugin</artifactId>
313                                         <version>1.2</version>
314                                         <executions>
315                                                 <execution>
316                                                         <id>sign</id>
317                                                         <goals>
318                                                                 <goal>sign</goal>
319                                                         </goals>
320                                                         <configuration>
321                                                                 <!--  skip>${skipSigning}</skip -->
322                                                                 <archive>target/${project.artifactId}-${project.version}.jar</archive>
323                                                         </configuration>
324                                                 </execution>
325                                                 <execution>
326                                                         <id>verify</id>
327                                                         <goals>
328                                                                 <goal>verify</goal>
329                                                         </goals>
330                                                         <configuration>
331                                                                 <archive>target/${project.artifactId}-${project.version}.jar</archive>
332                                                         </configuration>
333                                                 </execution>
334                                         </executions>
335                                         <configuration>
336                                                 <skip>true</skip>
337                                                 <alias>cadi</alias>
338                                                 <keystore>/Volumes/Data/src/cadi/keys/aaf_cadi.jks</keystore>
339                                                 <storepass>Surprise!</storepass>
340                                                 <keypass>Surprise!</keypass>
341                                                 <verbose>true</verbose>
342                                                 <certs>true</certs>
343                                         </configuration>
344                                 </plugin>
345                 
346                 
347                                 <plugin>
348                                         <artifactId>maven-release-plugin</artifactId>
349                                         <version>2.5.2</version>
350                                         <configuration>
351                                                 <goals>-s ${mvn.settings} deploy</goals>
352                                         </configuration>
353                                 </plugin>
354         
355                                 <plugin>
356                                         <artifactId>maven-assembly-plugin</artifactId>
357                                         <version>2.5.5</version>
358                                 </plugin>
359         
360                                 <plugin>
361                                         <groupId>org.apache.maven.plugins</groupId>
362                                         <artifactId>maven-deploy-plugin</artifactId>
363                                         <version>2.8.1</version>
364                                         <configuration>
365                                                 <skip>false</skip>
366                                         </configuration>
367         
368                                 </plugin>
369         
370                                 <plugin>
371                                         <groupId>org.apache.maven.plugins</groupId>
372                                         <artifactId>maven-dependency-plugin</artifactId>
373                                         <version>2.10</version>
374                                 </plugin>
375                                 
376                 <plugin>
377                         <groupId>org.apache.maven.plugins</groupId>
378                         <artifactId>maven-javadoc-plugin</artifactId>
379                         <version>2.10.4</version>
380                         <configuration>
381                         <failOnError>false</failOnError>
382                         </configuration>
383                         <executions>
384                                 <execution>
385                                         <id>attach-javadocs</id>
386                                         <goals>
387                                                 <goal>jar</goal>
388                                         </goals>
389                                 </execution>
390                         </executions>
391                 </plugin> 
392            
393            
394                <plugin>
395                       <groupId>org.apache.maven.plugins</groupId>
396                       <artifactId>maven-source-plugin</artifactId>
397                       <version>2.2.1</version>
398                       <executions>
399                         <execution>
400                           <id>attach-sources</id>
401                           <goals>
402                             <goal>jar-no-fork</goal>
403                           </goals>
404                         </execution>
405                       </executions>
406                     </plugin>
407         
408  
409                         
410                 <plugin>
411                                 <groupId>org.codehaus.mojo</groupId>
412                                 <artifactId>cobertura-maven-plugin</artifactId>
413                                 <version>2.7</version>
414                                 <configuration>
415                                         <formats>
416                                         <format>html</format>
417                                         <format>xml</format>
418                                   </formats>
419                                 </configuration>
420                  </plugin>
421
422                                 <!--This plugin's configuration is used to store Eclipse m2e settings 
423                                         only. It has no influence on the Maven build itself. -->
424                                 <plugin>
425                                         <groupId>org.eclipse.m2e</groupId>
426                                         <artifactId>lifecycle-mapping</artifactId>
427                                         <version>1.0.0</version>
428                                         <configuration>
429                                                 <lifecycleMappingMetadata>
430                                                         <pluginExecutions>
431                                                                 <pluginExecution>
432                                                                         <pluginExecutionFilter>
433                                                                                 <groupId>
434                                                                                         org.codehaus.mojo
435                                                                                 </groupId>
436                                                                                 <artifactId>
437                                                                                         jaxb2-maven-plugin
438                                                                                 </artifactId>
439                                                                                 <versionRange>
440                                                                                         [1.3,)
441                                                                                 </versionRange>
442                                                                                 <goals>
443                                                                                         <goal>xjc</goal>
444                                                                                 </goals>
445                                                                         </pluginExecutionFilter>
446                                                                         <action>
447                                                                                 <ignore />
448                                                                         </action>
449                                                                 </pluginExecution>
450                                                         </pluginExecutions>
451                                                 </lifecycleMappingMetadata>
452                                         </configuration>
453                                 </plugin>
454                                   <plugin>
455                                 <groupId>org.sonatype.plugins</groupId>
456                                 <artifactId>nexus-staging-maven-plugin</artifactId>
457                                 <version>1.6.7</version>
458                                 <extensions>true</extensions>
459                                 <configuration>
460                                         <nexusUrl>${nexusproxy}</nexusUrl>
461                                         <stagingProfileId>176c31dfe190a</stagingProfileId>
462                                         <serverId>ecomp-staging</serverId>
463                                 </configuration>
464                         </plugin> 
465                         
466                         <plugin>
467           <groupId>org.jacoco</groupId>
468           <artifactId>jacoco-maven-plugin</artifactId>
469           <version>${jacoco.version}</version>
470           <configuration>
471             <excludes>
472               <exclude>**/gen/**</exclude>
473               <exclude>**/generated-sources/**</exclude>
474               <exclude>**/yang-gen/**</exclude>
475               <exclude>**/pax/**</exclude>
476             </excludes>
477           </configuration>
478           <executions>
479
480             <execution>
481               <id>pre-unit-test</id>
482               <goals>
483                 <goal>prepare-agent</goal>
484               </goals>
485               <configuration>
486                 <destFile>${project.build.directory}/code-coverage/jacoco-ut.exec</destFile>
487                 <propertyName>surefireArgLine</propertyName>
488               </configuration>
489             </execution>
490             
491        
492             <execution>
493               <id>post-unit-test</id>
494               <phase>test</phase>
495               <goals>
496                 <goal>report</goal>
497               </goals>
498               <configuration>
499                 <dataFile>${project.build.directory}/code-coverage/jacoco-ut.exec</dataFile>
500                 <outputDirectory>${project.reporting.outputDirectory}/jacoco-ut</outputDirectory>
501               </configuration>
502             </execution>
503             <execution>
504               <id>pre-integration-test</id>
505               <phase>pre-integration-test</phase>
506               <goals>
507                 <goal>prepare-agent</goal>
508               </goals>
509               <configuration>
510                 <destFile>${project.build.directory}/code-coverage/jacoco-it.exec</destFile>
511
512                 <propertyName>failsafeArgLine</propertyName>
513               </configuration>
514             </execution>
515
516        
517             <execution>
518               <id>post-integration-test</id>
519               <phase>post-integration-test</phase>
520               <goals>
521                 <goal>report</goal>
522               </goals>
523               <configuration>
524                 <dataFile>${project.build.directory}/code-coverage/jacoco-it.exec</dataFile>
525                 <outputDirectory>${project.reporting.outputDirectory}/jacoco-it</outputDirectory>
526               </configuration>
527             </execution>
528           </executions>
529         </plugin>       
530
531                         </plugins>                      
532         </build>
533         <distributionManagement>
534                 <repository>
535                         <id>ecomp-releases</id>
536                         <name>AAF Release Repository</name>
537                         <url>${nexusproxy}${releaseNexusPath}</url>
538                 </repository>
539                 <snapshotRepository>
540                         <id>ecomp-snapshots</id>
541                         <name>AAF Snapshot Repository</name>
542                         <url>${nexusproxy}${snapshotNexusPath}</url>
543                 </snapshotRepository>
544                 <site>
545                         <id>ecomp-site</id>
546                         <url>dav:${nexusproxy}${sitePath}</url>
547                 </site>
548         </distributionManagement>
549 </project>