Improve aaf sonar code coverage
[aaf/authz.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"
24   xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
25
26         <modelVersion>4.0.0</modelVersion>
27         <groupId>org.onap.aaf.authz</groupId>
28         <artifactId>parent</artifactId>
29         <version>1.0.1-SNAPSHOT</version>
30         <name>aaf-authz</name>
31         <packaging>pom</packaging>
32         <url>https://github.com/att/AAF</url>
33         
34         <parent>             
35         <groupId>org.onap.oparent</groupId>
36         <artifactId>oparent</artifactId>
37         <version>0.1.1</version>
38     </parent>
39         
40         <licenses>
41                 <license>
42                 <name>BSD License</name>
43                 <url> </url>
44                 </license>
45         </licenses>
46         <developers>
47                 <developer>
48                 <name>Jonathan Gathman</name>
49                 <email></email>
50         <organization>ATT</organization>
51         <organizationUrl></organizationUrl>
52                 </developer>
53         </developers>
54         <description>This module is used to organize all of the common SWM (Software Manager) 
55                 artifacts and capabilities that are inherited by all modules that are SWM
56                 packaged.  This prevents duplication of these common artifacts, plugins, and 
57                 other settings and provides a single place to support this configuration.
58         </description>
59         <properties>
60                 <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
61                 <skipTests>false</skipTests>
62                 <project.interfaceVersion>1.0.0-SNAPSHOT</project.interfaceVersion>
63                 <project.innoVersion>1.0.0-SNAPSHOT</project.innoVersion>
64                 <project.cadiVersion>1.0.0-SNAPSHOT</project.cadiVersion>
65                 <project.dme2Version>3.1.200</project.dme2Version>
66                 <sonar.language>java</sonar.language>
67                 <sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>
68                 <sonar.surefire.reportsPath>${project.build.directory}/surefire-reports</sonar.surefire.reportsPath>
69                 <sonar.jacoco.reportPath>${project.build.directory}/coverage-reports/jacoco.exec</sonar.jacoco.reportPath>
70                 <sonar.jacoco.itReportPath>${project.build.directory}/coverage-reports/jacoco-it.exec</sonar.jacoco.itReportPath>
71                 <sonar.jacoco.reportMissing.force.zero>true</sonar.jacoco.reportMissing.force.zero>
72                 <sonar.projectVersion>${project.version}</sonar.projectVersion>
73                 <nexusproxy>https://nexus.onap.org</nexusproxy>
74                 <snapshotNexusPath>/content/repositories/snapshots/</snapshotNexusPath>
75                 <releaseNexusPath>/content/repositories/releases/</releaseNexusPath>
76                 <stagingNexusPath>/content/repositories/staging/</stagingNexusPath>
77                 <sitePath>/content/sites/site/org/onap/aaf/authz/${project.artifactId}/${project.version}</sitePath>
78         </properties>
79         <build>
80                 <pluginManagement>
81                 <plugins>
82                           <plugin>
83                                         <groupId>org.apache.maven.plugins</groupId>
84                                         <artifactId>maven-compiler-plugin</artifactId>
85                                         <version>2.3.2</version> 
86                                         <configuration>
87                                                 <source>1.8</source>
88                                                 <target>1.8</target>
89                                         </configuration>
90                                 </plugin>
91                                 
92         
93                                 <plugin>
94                                   <groupId>org.apache.maven.plugins</groupId>
95                                   <artifactId>maven-surefire-plugin</artifactId>
96                                   <version>2.17</version>
97                                   <configuration>
98                                         <skipTests>${skipTests}</skipTests>
99                                         <includes>
100                                           <include>**/JU*.java</include>
101                                         </includes>
102                                         <excludes>
103                                         <exclude>**/JU_DataFile.java</exclude>
104                                         <exclude>**/JU_ArtiDAO.java</exclude>
105                                         <exclude>**/JU_CertDAO.java</exclude>
106                                         <exclude>**/JU_FastCalling.java</exclude>
107                                         <exclude>**/JU_NsDAO.java</exclude>
108                                           <!-- <exclude>**/authz-cass/**</exclude> -->
109                                           <!-- <exclude>**/JU_UseCase1.java</exclude> -->
110                                           <exclude>**/JU_RoleDAO.java</exclude>
111                                           <exclude>**/JU_PermDAO.java</exclude>
112                                            <exclude>**/JU_Question.java</exclude> 
113                                           <!-- <exclude>**/JU_NS.java</exclude> -->
114                                           <exclude>**/JU_HistoryDAO.java</exclude>                                
115                                           <exclude>**/JU_DelegateDAO.java</exclude>
116                                           <exclude>**/JU_CredDAO.java</exclude>
117                                           <exclude>**/JU_CacheInfoDAO.java</exclude>
118                                           <exclude>**/JU_ApprovalDAO.java</exclude>
119                                           <exclude>**/JU_Define.java</exclude>
120                                           <exclude>**/JU_AuthzTransFilter.java</exclude>
121                                           <exclude>**/JU_CachingFileAccess.java</exclude>
122                                           <!-- <exclude>**/AbsServiceTest.java</exclude> -->
123                                           <exclude>**/JU_DefaultOrg.java</exclude>
124                                           <exclude>**/JU_FileServer.java</exclude>
125                                           <exclude>**/JU_DirectAAFLur.java</exclude>
126                                           <exclude>**/JU_AuthAPI.java</exclude>
127                                           <exclude>**/JU_GwAPI.java</exclude>
128                                           
129                                           <!-- <exclude>**/JU_Perm_2_0*.java</exclude> -->
130                                           <!-- <exclude>**/JU_Role_2_0*.java</exclude>                             -->
131                                         </excludes>
132         
133                                   </configuration>
134                                 </plugin>
135         
136                                 <plugin>
137                                         <groupId>org.codehaus.mojo</groupId>
138                                         <artifactId>jaxb2-maven-plugin</artifactId>
139                                         <version>1.3</version>
140                                         <executions>
141                                                 <execution>
142                                                         <phase>generate-sources</phase>
143                                                         <goals>
144                                                                 <goal>xjc</goal>
145                                                         </goals>
146                                                 </execution>
147                                         </executions>
148                                         <configuration>
149                                                 <schemaDirectory>src/main/xsd</schemaDirectory>
150                                         </configuration>
151                                 </plugin>
152         
153                                 <plugin>
154                                   <groupId>org.apache.maven.plugins</groupId>
155                                   <artifactId>maven-failsafe-plugin</artifactId>
156                                   <version>2.17</version>
157                                   <configuration>
158                                                 <skipTests>true</skipTests>
159                                   </configuration>
160                                   <executions>
161                                         <execution>
162                                           <id>integration-test</id>
163                                           <goals>
164                                                 <goal>integration-test</goal>
165                                                 <goal>verify</goal>
166                                           </goals>
167                                         </execution>
168                                   </executions>
169                                 </plugin>
170                                 <plugin>
171                                         <groupId>org.apache.maven.plugins</groupId>
172                                         <artifactId>maven-jarsigner-plugin</artifactId>
173                                         <version>1.2</version>
174                                         <executions>
175                                                 <execution>
176                                                         <id>sign</id>
177                                                         <goals>
178                                                                 <goal>sign</goal>
179                                                         </goals>
180                                                         <configuration>
181                                                                 <!--  skip>${skipSigning}</skip -->
182                                                                 <archive>target/${project.artifactId}-${project.version}.jar</archive>
183                                                         </configuration>
184                                                 </execution>
185                                                 <execution>
186                                                         <id>verify</id>
187                                                         <goals>
188                                                                 <goal>verify</goal>
189                                                         </goals>
190                                                         <configuration>
191                                                                 <archive>target/${project.artifactId}-${project.version}.jar</archive>
192                                                         </configuration>
193                                                 </execution>
194                                         </executions>
195                                         <configuration>
196                                                 <skip>true</skip>
197                                                 <alias>aaf</alias>
198                                                 <keystore>/Volumes/Data/src/cadi/keys/aaf_cadi.jks</keystore>
199                                                 <storepass>Surprise!</storepass>
200                                                 <keypass>Surprise!</keypass>
201                                                 <verbose>true</verbose>
202                                                 <certs>true</certs>
203                                         </configuration>
204                                 </plugin>
205                                 
206                 <plugin>
207                         <groupId>org.apache.maven.plugins</groupId>
208                         <artifactId>maven-javadoc-plugin</artifactId>
209                         <version>2.10.4</version>
210                         <configuration>
211                         <failOnError>false</failOnError>
212                         </configuration>
213                         <executions>
214                                 <execution>
215                                         <id>attach-javadocs</id>
216                                         <goals>
217                                                 <goal>jar</goal>
218                                         </goals>
219                                 </execution>
220                         </executions>
221                 </plugin> 
222
223
224            
225                <plugin>
226                       <groupId>org.apache.maven.plugins</groupId>
227                       <artifactId>maven-source-plugin</artifactId>
228                       <version>2.2.1</version>
229                       <executions>
230                         <execution>
231                           <id>attach-sources</id>
232                           <goals>
233                             <goal>jar-no-fork</goal>
234                           </goals>
235                         </execution>
236                       </executions>
237                     </plugin>
238
239                         
240                 <plugin>
241                                 <groupId>org.codehaus.mojo</groupId>
242                                 <artifactId>cobertura-maven-plugin</artifactId>
243                                 <version>2.7</version>
244                                 <configuration>
245                                         <formats>
246                                         <format>html</format>
247                                         <format>xml</format>
248                                   </formats>
249                                 </configuration>
250                         </plugin>
251                 <plugin>
252                                 <groupId>org.sonatype.plugins</groupId>
253                                 <artifactId>nexus-staging-maven-plugin</artifactId>
254                                 <version>1.6.7</version>
255                                 <extensions>true</extensions>
256                                 <configuration>
257                                         <nexusUrl>${nexusproxy}</nexusUrl>
258                                         <stagingProfileId>176c31dfe190a</stagingProfileId>
259                                         <serverId>ecomp-staging</serverId>
260                                 </configuration>
261                         </plugin>               
262                         <plugin>
263                                 <groupId>org.jacoco</groupId>
264                                 <artifactId>jacoco-maven-plugin</artifactId>
265                                 <version>0.7.7.201606060606</version>
266                                 <configuration>
267                                         <dumpOnExit>true</dumpOnExit>
268                                         <includes>
269                                                 <include>org.onap.aaf.*</include>
270                                         </includes>
271                                 </configuration>
272                                 <executions>
273                                         <execution>
274                                                 <id>pre-unit-test</id>
275                                                 <goals>
276                                                         <goal>prepare-agent</goal>
277                                                 </goals>
278                                                 <configuration>
279                                                         <destFile>${project.build.directory}/coverage-reports/jacoco.exec</destFile>
280                                                         <!-- <append>true</append> -->
281                                                 </configuration>
282                                         </execution>
283                                         <execution>
284                                                 <id>pre-integration-test</id>
285                                                 <phase>pre-integration-test</phase>
286                                                 <goals>
287                                                         <goal>prepare-agent</goal>
288                                                 </goals>
289                                                 <configuration>
290                                                         <destFile>${project.build.directory}/coverage-reports/jacoco-it.exec</destFile>
291                                                         <!-- <append>true</append> -->
292                                                 </configuration>
293                                         </execution>
294                                         <execution>
295                         <goals>
296                             <goal>merge</goal>
297                         </goals>
298                         <phase>post-integration-test</phase>
299                         <configuration>
300                             <fileSets>
301                                 <fileSet implementation="org.apache.maven.shared.model.fileset.FileSet">
302                                     <directory>${project.build.directory}/coverage-reports</directory>
303                                     <includes>
304                                         <include>*.exec</include>
305                                     </includes>
306                                 </fileSet>
307                             </fileSets>
308                             <destFile>${project.build.directory}/jacoco-dev.exec</destFile>
309                         </configuration>
310                     </execution>
311                                 </executions>
312                         </plugin>
313                                 
314                 </plugins>
315                 </pluginManagement>                     
316     </build>    
317         
318         <dependencies> 
319                 <dependency>
320                         <groupId>junit</groupId>
321                         <artifactId>junit</artifactId>
322                         <version>4.10</version>
323                         <scope>test</scope>
324                 </dependency>
325
326                 <dependency>
327                     <groupId>org.mockito</groupId>
328                     <artifactId>mockito-core</artifactId>
329                     <version>1.10.19</version>
330                     <scope>test</scope>
331                 </dependency>
332                 <dependency>
333                     <groupId>org.powermock</groupId>
334                     <artifactId>powermock-module-junit4</artifactId>
335                     <version>1.6.4</version>
336                     <scope>test</scope>
337                 </dependency>
338                 <dependency>
339                     <groupId>org.powermock</groupId>
340                     <artifactId>powermock-api-mockito</artifactId>
341                     <version>1.6.4</version>
342                     <scope>test</scope>
343                 </dependency> 
344
345          
346         </dependencies>         
347
348         <modules>
349                 <!-- 
350                    <module> auth-client</module>
351                    complile manually with mvn -N independently
352                 -->
353                 <module>authz-client</module>
354                 <module>authz-core</module>
355                 <module>authz-cass</module>
356                 <module>authz-defOrg</module>
357                 <module>authz-cmd</module>
358                 <!--  <module>authz-batch</module>-->
359                 <module>authz-test</module>
360                 <!--  <module>authz-gui</module> -->
361                 <module>authz-gw</module>
362                 <module>authz-certman</module>
363                 <module>authz-fs</module>
364                 <module>authz-service</module>
365         </modules>
366         
367         <dependencyManagement>
368                 <dependencies>
369                         <dependency>
370                                 <groupId>org.onap.aaf.inno</groupId>
371                                 <artifactId>env</artifactId>
372                                 <version>${project.innoVersion}</version>
373                         </dependency>
374
375                         <dependency>
376                                 <groupId>org.onap.aaf.inno</groupId>
377                                 <artifactId>log4j</artifactId>
378                                 <version>${project.innoVersion}</version>
379                         </dependency>
380
381                         <dependency>
382                                 <groupId>org.onap.aaf.inno</groupId>
383                                 <artifactId>rosetta</artifactId>
384                                 <version>${project.innoVersion}</version>
385                         </dependency>
386
387                         <dependency>
388                                 <groupId>org.onap.aaf.inno</groupId>
389                                 <artifactId>xgen</artifactId>
390                                 <version>${project.innoVersion}</version>
391                         </dependency>
392                         
393                         <dependency>
394                                 <groupId>org.onap.aaf.cadi</groupId>
395                                 <artifactId>cadi-core</artifactId>
396                                 <version>${project.cadiVersion}</version>
397                         </dependency>
398
399                         <dependency>
400                                 <groupId>org.onap.aaf.cadi</groupId>
401                                 <artifactId>cadi-client</artifactId>
402                                 <version>${project.cadiVersion}</version>
403                         </dependency>
404                         
405                         
406                         <dependency>
407                                 <groupId>org.onap.aaf.cadi</groupId>
408                                 <artifactId>cadi-aaf</artifactId>
409                                 <version>${project.cadiVersion}</version>
410                                 <exclusions>
411                               <exclusion> 
412                                         <groupId>org.apache.cassandra</groupId>
413                                 <artifactId>cassandra-all</artifactId>
414                       </exclusion>
415                             </exclusions> 
416                         </dependency>
417                         
418                         <dependency>
419                                 <groupId>org.onap.aaf.authz</groupId>
420                                 <artifactId>authz-client</artifactId>
421                                 <version>${project.interfaceVersion}</version>
422                         </dependency>
423                         
424                         
425                         <dependency>
426                                 <groupId>org.onap.aaf.authz</groupId>
427                                 <artifactId>authz-core</artifactId>
428                                 <version>${project.version}</version>
429                         </dependency>
430                         
431                         <dependency>
432                     <groupId>org.onap.aaf.authz</groupId>
433                     <artifactId>authz-cass</artifactId>
434                                 <version>${project.version}</version>
435                 </dependency>
436                 
437                 <dependency>
438                                 <groupId>org.onap.aaf.authz</groupId>
439                                 <artifactId>authz-batch</artifactId>
440                                 <version>${project.interfaceVersion}</version>
441                         </dependency>
442             
443
444
445                     <dependency>
446                     <groupId>org.onap.aaf.authz</groupId>
447                     <artifactId>authz-cmd</artifactId>
448                                 <version>${project.version}</version>
449                 </dependency>
450                 <dependency>
451                     <groupId>org.onap.aaf.authz</groupId>
452                     <artifactId>authz-gw</artifactId>
453                                 <version>${project.version}</version>
454                 </dependency>
455
456                         <dependency>
457                                 <groupId>com.att.aft</groupId>
458                                 <artifactId>dme2</artifactId>
459                                 <version>${project.dme2Version}</version>
460                         </dependency>
461                 
462                         <dependency>
463                           <groupId>javax.servlet</groupId>
464                           <artifactId>servlet-api</artifactId>
465                           <version>2.5</version>
466                         </dependency>
467                         
468                         <dependency>
469                                 <groupId>org.eclipse.jetty</groupId>
470                                 <artifactId>jetty-servlet</artifactId>
471                                 <version>9.0.3.v20130506</version>
472                         </dependency>
473                         
474                         <dependency>
475                                 <groupId>com.datastax.cassandra</groupId>
476                                 <artifactId>cassandra-all</artifactId>
477                                 <version>2.1.10</version>
478                                 <exclusions>
479                               <exclusion> 
480                                 <groupId>org.slf4j</groupId>
481                                 <artifactId>slf4j-log4j12</artifactId>
482                               </exclusion>
483                               <exclusion> 
484                                 <groupId>log4j</groupId>
485                                 <artifactId>log4j</artifactId>
486                               </exclusion>
487                             </exclusions> 
488                         </dependency>
489                         <dependency>
490                                 <groupId>com.datastax.cassandra</groupId>
491                                 <artifactId>cassandra-driver-core</artifactId>
492                                 <!-- version>1.0.3</version -->
493                                 <!-- version>1.0.5</version -->
494                                 <version>2.1.10</version>
495                                 <exclusions>
496                               <exclusion> 
497                                 <groupId>org.slf4j</groupId>
498                                 <artifactId>slf4j-log4j12</artifactId>
499                               </exclusion>
500                               <exclusion> 
501                                 <groupId>log4j</groupId>
502                                 <artifactId>log4j</artifactId>
503                               </exclusion>
504                             </exclusions> 
505                         </dependency>   
506
507                         <dependency>
508                                 <groupId>org.slf4j</groupId>
509                                 <artifactId>slf4j-log4j12</artifactId>
510                                 <version>1.7.5</version>
511                         </dependency>
512
513                         <dependency>
514                         <groupId>javax.mail</groupId>
515                         <artifactId>mail</artifactId>
516                         <version>1.4.5</version>
517                 </dependency> 
518
519                         
520                 </dependencies>
521         </dependencyManagement>
522         <distributionManagement>
523                 <repository>
524                         <id>ecomp-releases</id>
525                         <name>AAF Release Repository</name>
526                         <url>${nexusproxy}${releaseNexusPath}</url>
527                 </repository>
528                 <snapshotRepository>
529                         <id>ecomp-snapshots</id>
530                         <name>AAF Snapshot Repository</name>
531                         <url>${nexusproxy}${snapshotNexusPath}</url>
532                 </snapshotRepository>
533                 <site>
534                         <id>ecomp-site</id>
535                         <url>dav:${nexusproxy}${sitePath}</url>
536                 </site>
537         </distributionManagement>
538
539 </project>