Fix broken test coverage
[sdc/sdc-tosca.git] / pom.xml
1 <project xmlns="http://maven.apache.org/POM/4.0.0"
2     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3     xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
4
5     <modelVersion>4.0.0</modelVersion>
6
7     <groupId>org.onap.sdc.sdc-tosca</groupId>
8     <artifactId>sdc-tosca-jtosca</artifactId>
9     <name>sdc-tosca-jtosca</name>
10     <description>SDC Tosca Parser JAR file for use by consumers</description>
11     <version>1.7.0-SNAPSHOT</version>
12     <packaging>pom</packaging>
13
14     <parent>
15         <groupId>org.onap.oparent</groupId>
16         <artifactId>oparent</artifactId>
17         <version>3.2.0</version>
18         <relativePath/>
19     </parent>
20
21     <modules>
22         <module>sdc-tosca</module>
23         <module>jtosca</module>
24     </modules>
25
26     <properties>
27
28         <!-- ==================== -->
29         <!-- Generic properties -->
30         <!-- ==================== -->
31         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
32
33         <!-- ==================== -->
34         <!-- Versions -->
35         <hamcrest.version>2.1</hamcrest.version>
36         <!-- ==================== -->
37         <!-- Global project version -->
38
39         <!-- Dependencies projects version -->
40         <nexus.proxy>https://nexus.onap.org</nexus.proxy>
41         <sitePath>/content/sites/site/org/onap/sdc/sdc-tosca/${project.version}</sitePath>
42         <snapshots.path>snapshots</snapshots.path>
43         <releases.path>releases</releases.path>
44
45         <!-- Sonar properties -->
46         <sonar.coverage.exclusions>pom.xml,src/test</sonar.coverage.exclusions>
47         <sonar.coverage.jacoco.xmlReportPaths>${project.reporting.outputDirectory}/jacoco-ut/jacoco.xml</sonar.coverage.jacoco.xmlReportPaths>
48         <sonar.exclusions>**/scripts/**/*</sonar.exclusions>
49         <sonar.inclusions>app/**/*.js,server-mock/**/*.js,src/**/*.js,src/main/**/*.java</sonar.inclusions>
50         <sonar.javascript.lcov.reportPaths>${project.build.directory}/code-coverage/lcov.info</sonar.javascript.lcov.reportPaths>
51         <sonar.language>java</sonar.language>
52         <sonar.nodejs.executable>${project.basedir}/node/node</sonar.nodejs.executable>
53         <sonar.projectBaseDir>${project.basedir}</sonar.projectBaseDir>
54         <sonar.projectVersion>${project.version}</sonar.projectVersion>
55         <sonar.sourceEncoding>${project.build.sourceEncoding}</sonar.sourceEncoding>
56         <sonar.sources>.</sonar.sources>
57         <sonar.surefire.reportsPath>${project.build.directory}/surefire-reports</sonar.surefire.reportsPath>
58         <sonar.test.exclusions>**/test/**/*,**/tests/**/*</sonar.test.exclusions>
59
60         <lombok.version>1.18.20</lombok.version>
61         <!--TESTING-->
62         <mockito.version>4.3.1</mockito.version>
63         <mockitoJupiter.version>${mockito.version}</mockitoJupiter.version>
64         <junit.platform.version>1.8.2</junit.platform.version>
65         <junitJupiter.version>5.8.2</junitJupiter.version>
66         <!--jacoco-->
67         <jacoco.version>0.8.8</jacoco.version>
68     </properties>
69
70     <dependencyManagement>
71         <dependencies>
72             <dependency>
73                 <groupId>org.projectlombok</groupId>
74                 <artifactId>lombok</artifactId>
75                 <version>${lombok.version}</version>
76             </dependency>
77             <dependency>
78                 <groupId>org.hamcrest</groupId>
79                 <artifactId>hamcrest-library</artifactId>
80                 <version>${hamcrest.version}</version>
81             </dependency>
82             <!--JUnit Jupiter Engine to depend on the JUnit5 engine and JUnit 5 API -->
83             <dependency>
84                 <groupId>org.junit.jupiter</groupId>
85                 <artifactId>junit-jupiter</artifactId>
86                 <version>${junitJupiter.version}</version>
87             </dependency>
88             <dependency>
89                 <groupId>org.mockito</groupId>
90                 <artifactId>mockito-junit-jupiter</artifactId>
91                 <version>${mockitoJupiter.version}</version>
92             </dependency>
93         </dependencies>
94     </dependencyManagement>
95
96     <dependencies>
97         <dependency>
98             <!-- must be on the classpath -->
99             <groupId>org.jacoco</groupId>
100             <artifactId>org.jacoco.agent</artifactId>
101             <classifier>runtime</classifier>
102             <version>${jacoco.version}</version>
103             <scope>test</scope>
104         </dependency>
105         <dependency>
106             <groupId>org.slf4j</groupId>
107             <artifactId>slf4j-api</artifactId>
108             <version>1.7.36</version>
109         </dependency>
110
111         <dependency>
112             <groupId>com.google.guava</groupId>
113             <artifactId>guava</artifactId>
114             <scope>compile</scope>
115             <version>31.1-jre</version>
116         </dependency>
117
118         <!-- YAML parser -->
119         <dependency>
120             <groupId>org.yaml</groupId>
121             <artifactId>snakeyaml</artifactId>
122             <version>1.30</version>
123             <scope>compile</scope>
124         </dependency>
125
126         <!-- TEST -->
127         <dependency>
128             <groupId>org.assertj</groupId>
129             <artifactId>assertj-core</artifactId>
130             <version>3.22.0</version>
131             <scope>test</scope>
132         </dependency>
133
134         <dependency>
135             <groupId>org.mockito</groupId>
136             <artifactId>mockito-junit-jupiter</artifactId>
137             <scope>test</scope>
138         </dependency>
139     </dependencies>
140
141     <reporting>
142         <plugins>
143             <plugin>
144                 <groupId>org.apache.maven.plugins</groupId>
145                 <artifactId>maven-javadoc-plugin</artifactId>
146                 <configuration>
147                     <failOnError>false</failOnError>
148                     <doclet>org.umlgraph.doclet.UmlGraphDoc</doclet>
149                     <docletArtifact>
150                         <groupId>org.umlgraph</groupId>
151                         <artifactId>umlgraph</artifactId>
152                         <version>5.6.6</version>
153                     </docletArtifact>
154                     <additionalparam>-views</additionalparam>
155                     <useStandardDocletOptions>true</useStandardDocletOptions>
156                 </configuration>
157             </plugin>
158         </plugins>
159     </reporting>
160
161     <build>
162         <pluginManagement>
163             <plugins>
164                 <plugin>
165                     <groupId>org.jacoco</groupId>
166                     <artifactId>jacoco-maven-plugin</artifactId>
167                     <version>${jacoco.version}</version>
168                 </plugin>
169                 <plugin>
170                     <groupId>org.apache.maven.plugins</groupId>
171                     <artifactId>maven-compiler-plugin</artifactId>
172                     <version>3.10.1</version>
173                 </plugin>
174                 <plugin>
175                     <groupId>org.apache.maven.plugins</groupId>
176                     <artifactId>maven-checkstyle-plugin</artifactId>
177                     <version>3.1.2</version>
178                 </plugin>
179                 <plugin>
180                     <groupId>org.apache.maven.plugins</groupId>
181                     <artifactId>maven-javadoc-plugin</artifactId>
182                     <version>3.3.2</version>
183                     <configuration/>
184                 </plugin>
185                 <plugin>
186                     <groupId>org.apache.maven.plugins</groupId>
187                     <artifactId>maven-surefire-plugin</artifactId>
188                     <version>2.22.2</version>
189                 </plugin>
190                 <plugin>
191                     <groupId>org.apache.maven.plugins</groupId>
192                     <artifactId>maven-site-plugin</artifactId>
193                     <version>3.11.0</version>
194                     <dependencies>
195                         <dependency>
196                             <groupId>org.apache.maven.wagon</groupId>
197                             <artifactId>wagon-webdav-jackrabbit</artifactId>
198                             <version>3.5.1</version>
199                         </dependency>
200                     </dependencies>
201                 </plugin>
202             </plugins>
203         </pluginManagement>
204
205         <plugins>
206             <plugin>
207                 <groupId>org.apache.maven.plugins</groupId>
208                 <artifactId>maven-site-plugin</artifactId>
209                 <version>3.11.0</version>
210                 <dependencies>
211                     <dependency>
212                         <groupId>org.apache.maven.wagon</groupId>
213                         <artifactId>wagon-webdav-jackrabbit</artifactId>
214                         <version>3.5.1</version>
215                     </dependency>
216                 </dependencies>
217             </plugin>
218
219             <plugin>
220                 <groupId>org.apache.maven.plugins</groupId>
221                 <artifactId>maven-checkstyle-plugin</artifactId>
222                 <configuration>
223                     <suppressionsLocation>checkstyle-suppressions.xml</suppressionsLocation>
224                     <suppressionsFileExpression>checkstyle.suppressions.file</suppressionsFileExpression>
225                     <skip>true</skip>
226                 </configuration>
227             </plugin>
228
229             <!-- Java Code Coverage -->
230             <plugin>
231                 <groupId>org.jacoco</groupId>
232                 <artifactId>jacoco-maven-plugin</artifactId>
233                 <inherited>false</inherited>
234                 <executions>
235                     <execution>
236                         <id>default-instrument</id>
237                         <goals>
238                             <goal>instrument</goal>
239                         </goals>
240                     </execution>
241                     <execution>
242                         <id>default-restore-instrumented-classes</id>
243                         <goals>
244                             <goal>restore-instrumented-classes</goal>
245                         </goals>
246                     </execution>
247                     <execution>
248                         <id>default-report</id>
249                         <goals>
250                             <goal>report</goal>
251                         </goals>
252                         <configuration>
253                             <dataFile>${project.build.directory}/jacoco.exec</dataFile>
254                         </configuration>
255                     </execution>
256                 </executions>
257             </plugin>
258
259             <plugin>
260                 <groupId>org.apache.maven.plugins</groupId>
261                 <artifactId>maven-compiler-plugin</artifactId>
262                 <configuration>
263                     <source>11</source>
264                     <target>11</target>
265                     <forceJavacCompilerUse>true</forceJavacCompilerUse>
266                 </configuration>
267             </plugin>
268             <plugin>
269                 <groupId>org.apache.maven.plugins</groupId>
270                 <artifactId>maven-javadoc-plugin</artifactId>
271                 <configuration/>
272             </plugin>
273             <!-- Test -->
274             <plugin>
275                 <groupId>org.apache.maven.plugins</groupId>
276                 <artifactId>maven-surefire-plugin</artifactId>
277                 <dependencies>
278                     <dependency>
279                         <groupId>org.apache.maven.surefire</groupId>
280                         <artifactId>surefire-junit-platform</artifactId>
281                         <version>2.22.2</version>
282                     </dependency>
283                 </dependencies>
284                 <configuration>
285                     <printSummary>false</printSummary>
286                     <systemPropertyVariables>
287                         <jacoco-agent.destfile>${project.build.directory}/jacoco.exec</jacoco-agent.destfile>
288                     </systemPropertyVariables>
289                 </configuration>
290             </plugin>
291
292             <plugin>
293                 <groupId>com.github.sylvainlaurent.maven</groupId>
294                 <artifactId>yaml-json-validator-maven-plugin</artifactId>
295                 <version>1.0.1</version>
296                 <executions>
297                     <execution>
298                         <id>validate</id>
299                         <phase>validate</phase>
300                         <goals>
301                             <goal>validate</goal>
302                         </goals>
303                         <configuration>
304                             <validationSets>
305                                 <validationSet>
306                                     <includes>
307                                         <include>src/main/resources/**/*.y*ml</include>
308                                         <include>src/test/resources/**/*.y*ml</include>
309                                     </includes>
310                                 </validationSet>
311                                 <validationSet>
312                                     <includes>
313                                         <include>src/main/resources/**/*.json</include>
314                                         <include>src/test/resources/**/*.json</include>
315                                     </includes>
316                                 </validationSet>
317                             </validationSets>
318                         </configuration>
319                     </execution>
320                 </executions>
321             </plugin>
322         </plugins>
323     </build>
324
325     <repositories>
326         <repository>
327             <id>central</id>
328             <name>Official Maven repository</name>
329             <url>http://repo2.maven.org/maven2/</url>
330         </repository>
331         <repository>
332             <id>ecomp-releases</id>
333             <name>Release Repository</name>
334             <url>${nexus.proxy}/content/repositories/releases/</url>
335         </repository>
336         <repository>
337             <id>ecomp-snapshots</id>
338             <name>Snapshots Repository</name>
339             <url>${nexus.proxy}/content/repositories/snapshots/</url>
340         </repository>
341     </repositories>
342
343     <distributionManagement>
344         <repository>
345             <id>ecomp-releases</id>
346             <name>Release Repository</name>
347             <url>${nexus.proxy}/content/repositories/${releases.path}/</url>
348         </repository>
349         <snapshotRepository>
350             <id>ecomp-snapshots</id>
351             <name>Snapshot Repository</name>
352             <url>${nexus.proxy}/content/repositories/${snapshots.path}/</url>
353         </snapshotRepository>
354         <site>
355             <id>ecomp-site</id>
356             <url>dav:${nexus.proxy}${sitePath}</url>
357         </site>
358     </distributionManagement>
359 </project>