blob: 25c1274391d8adc6a5bb55525de69481e3cfb5e4 [file] [log] [blame]
JohnKeeneyf1e44602024-06-07 13:07:03 +01001<?xml version="1.0" encoding="UTF-8"?>
2<!-- spotless:off -->
3<!--
4 ============LICENSE_START=======================================================
5 Copyright (C) 2024 Ericsson
6 Modifications Copyright (C) 2024 OpenInfra Foundation Europe
7 ================================================================================
8 Licensed under the Apache License, Version 2.0 (the "License");
9 you may not use this file except in compliance with the License.
10 You may obtain a copy of the License at
11
12 http://www.apache.org/licenses/LICENSE-2.0
13
14 Unless required by applicable law or agreed to in writing, software
15 distributed under the License is distributed on an "AS IS" BASIS,
16 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 See the License for the specific language governing permissions and
18 limitations under the License.
19
20 SPDX-License-Identifier: Apache-2.0
21 ============LICENSE_END=========================================================
22 -->
23<!-- spotless:on -->
24<project xmlns="http://maven.apache.org/POM/4.0.0"
25 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
26 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
27 <modelVersion>4.0.0</modelVersion>
28 <parent>
29 <groupId>org.oran.smo</groupId>
30 <artifactId>topology-exposure-inventory</artifactId>
JohnKeeneyb6cfcb42024-06-24 11:40:51 +010031 <version>0.1.0-SNAPSHOT</version>
JohnKeeneyf1e44602024-06-07 13:07:03 +010032 </parent>
33
34 <groupId>org.oran.smo.yangtools.parser</groupId>
35 <artifactId>yang-parser-jar</artifactId>
36 <name>Yang Parser</name>
JohnKeeneyb6cfcb42024-06-24 11:40:51 +010037 <version>1.1.0-SNAPSHOT</version>
JohnKeeneyf1e44602024-06-07 13:07:03 +010038 <packaging>jar</packaging>
39
40 <properties>
41 <maven.javadoc.skip>true</maven.javadoc.skip>
42 <sonar.tests>src/test/java</sonar.tests>
43 <sonar.sources>pom.xml,src/main/java</sonar.sources>
44 <sonar.exclusions>**/*.java</sonar.exclusions>
45 <!-- External Yang model destination location -->
46 <src.modules>${project.basedir}/src/main/resources/modules/</src.modules>
47 <src.test.orig.modules>${project.basedir}/src/test/resources/_orig-modules/</src.test.orig.modules>
48 </properties>
49
50 <build>
51 <resources>
52 <resource>
53 <directory>src/main/resources</directory>
54 <filtering>true</filtering>
55 </resource>
56 </resources>
57 <plugins>
58 <plugin>
59 <groupId>org.apache.maven.plugins</groupId>
60 <artifactId>maven-surefire-plugin</artifactId>
61 <version>3.0.0-M3</version>
62 <configuration>
63 <useFile>false</useFile>
64 <includes>
65 <include>**/*Test.java</include>
66 </includes>
67 <testSourceDirectory>${project.basedir}/src/test/java</testSourceDirectory>
68 </configuration>
69 </plugin>
70 <plugin>
71 <groupId>com.mycila</groupId>
72 <artifactId>license-maven-plugin</artifactId>
73 <version>${version.license-maven-plugin}</version>
74 <executions>
75 <execution>
76 <goals>
77 <goal>check</goal>
78 </goals>
79 </execution>
80 </executions>
81 </plugin>
82 <plugin>
83 <groupId>com.diffplug.spotless</groupId>
84 <artifactId>spotless-maven-plugin</artifactId>
85 <version>${version.spotless-plugin}</version>
86 <executions>
87 <execution>
88 <goals>
89 <goal>check</goal>
90 </goals>
91 </execution>
92 </executions>
93 </plugin>
94 <plugin>
95 <groupId>org.apache.maven.plugins</groupId>
96 <artifactId>maven-antrun-plugin</artifactId>
97 <version>${version.antrun-maven-plugin}</version>
98 <executions>
99 <execution>
100 <id>download-src-external-yang-models</id>
101 <phase>initialize</phase>
102 <configuration>
103 <target>
104 <mkdir dir="${src.modules}" />
105 <resources id="src-ietf-yang-downloads">
106 <url
107 url="${source.ietfcatalog}ietf-yang-library@2019-01-04.yang" />
108 <url
109 url="${source.ietfcatalog}ietf-datastores@2018-02-14.yang" />
110 <url
111 url="${source.ietfcatalog}ietf-inet-types@2019-11-04.yang" />
112 <url
113 url="${source.ietfcatalog}ietf-yang-types@2019-11-04.yang" />
114 </resources>
115 <get dest="${src.modules}" skipexisting="true">
116 <resources refid="src-ietf-yang-downloads" />
117 <mapper type="regexp" from="^.*/([^/@]+)@([^/]+)$"
118 to="\1-\2" />
119 </get>
120 </target>
121 </configuration>
122 <goals>
123 <goal>run</goal>
124 </goals>
125 </execution>
126 <execution>
127 <id>download-test-external-yang-models</id>
128 <phase>generate-test-sources</phase>
129 <configuration>
130 <target>
131 <get
132 src="${source.3gpp.Rel18_SA98}_3gpp-common-yang-extensions.yang"
133 dest="${src.test.orig.modules}_3gpp-common-yang-extensions-2022-10-20.yang"
134 skipexisting="true" />
135 <get
136 src="${source.3gpp.Rel17_SA91}_3gpp-common-yang-extensions.yang"
137 dest="${src.test.orig.modules}_3gpp-common-yang-extensions-2019-06-23.yang"
138 skipexisting="true" />
139
140 <resources id="orig-ietf-yang-downloads">
141 <!-- spotless:off -->
142 <url url="${source.ietfcatalog}iana-crypt-hash@2014-08-06.yang"/>
143 <url url="${source.ietfcatalog}ietf-crypto-types@2019-11-20.yang" />
144 <url url="${source.ietfcatalog}ietf-datastores@2018-02-14.yang"/>
145 <url url="${source.ietfcatalog}ietf-inet-types@2019-11-04.yang"/>
146 <url url="${source.ietfcatalog}ietf-interfaces@2018-02-20.yang"/>
147 <url url="${source.ietfcatalog}ietf-ip@2018-02-22.yang"/>
148 <url url="${source.ietfcatalog}ietf-keystore@2019-11-20.yang"/>
149 <url url="${source.ietfcatalog}ietf-netconf-acm@2018-02-14.yang"/>
150 <url url="${source.ietfcatalog}ietf-netconf-client@2019-11-20.yang"/>
151 <url url="${source.ietfcatalog}ietf-netconf-monitoring@2010-10-04.yang"/>
152 <url url="${source.ietfcatalog}ietf-netconf-notifications@2012-02-06.yang"/>
153 <url url="${source.ietfcatalog}ietf-netconf-server@2018-09-20.yang"/>
154 <url url="${source.ietfcatalog}ietf-netconf-with-defaults@2011-06-01.yang"/>
155 <url url="${source.ietfcatalog}ietf-netconf@2011-06-01.yang"/>
156 <url url="${source.ietfcatalog}ietf-network-instance@2019-01-21.yang"/>
157 <url url="${source.ietfcatalog}ietf-origin@2018-02-14.yang"/>
158 <url url="${source.ietfcatalog}ietf-restconf-monitoring@2017-01-26.yang"/>
159 <url url="${source.ietfcatalog}ietf-restconf@2017-01-26.yang"/>
160 <url url="${source.ietfcatalog}ietf-ssh-client@2019-11-20.yang"/>
161 <url url="${source.ietfcatalog}ietf-ssh-common@2019-11-20.yang"/>
162 <url url="${source.ietfcatalog}ietf-ssh-server@2019-11-20.yang"/>
163 <url url="${source.ietfcatalog}ietf-subscribed-notifications@2019-05-06.yang"/>
164 <url url="${source.ietfcatalog}ietf-system@2014-08-06.yang"/>
165 <url url="${source.ietfcatalog}ietf-tcp-client@2019-10-18.yang"/>
166 <url url="${source.ietfcatalog}ietf-tcp-common@2019-10-18.yang"/>
167 <url url="${source.ietfcatalog}ietf-tcp-server@2019-10-18.yang"/>
168 <url url="${source.ietfcatalog}ietf-tls-client@2019-11-20.yang"/>
169 <url url="${source.ietfcatalog}ietf-tls-common@2019-11-20.yang"/>
170 <url url="${source.ietfcatalog}ietf-tls-server@2019-11-20.yang"/>
171 <url url="${source.ietfcatalog}ietf-trust-anchors@2019-04-29.yang"/>
172 <url url="${source.ietfcatalog}ietf-truststore@2019-11-20.yang"/>
173 <url url="${source.ietfcatalog}ietf-x509-cert-to-name@2014-12-10.yang"/>
174 <url url="${source.ietfcatalog}ietf-yang-library@2019-01-04.yang"/>
175 <url url="${source.ietfcatalog}ietf-yang-metadata@2016-08-05.yang"/>
176 <url url="${source.ietfcatalog}ietf-yang-patch@2017-02-22.yang"/>
177 <url url="${source.ietfcatalog}ietf-yang-push@2019-05-21.yang"/>
178 <url url="${source.ietfcatalog}ietf-yang-schema-mount@2019-01-14.yang"/>
179 <url url="${source.ietfcatalog}ietf-yang-types@2010-09-24.yang"/>
180 <url url="${source.ietfcatalog}ietf-yang-types@2019-11-04.yang"/>
181 <!-- spotless:on -->
182 </resources>
183 <get dest="${src.test.orig.modules}" skipexisting="true">
184 <resources refid="orig-ietf-yang-downloads" />
185 <mapper type="regexp" from="^.*/([^/@]+)@([^/]+)$"
186 to="\1-\2" />
187 </get>
188 </target>
189 </configuration>
190 <goals>
191 <goal>run</goal>
192 </goals>
193 </execution>
194 </executions>
195 </plugin>
aravind.estea1ce622024-07-01 15:43:25 +0100196 <plugin>
197 <groupId>org.jacoco</groupId>
198 <artifactId>jacoco-maven-plugin</artifactId>
199 <version>${version.jacoco-maven.plugin}</version>
200 <configuration>
201 <append>true</append>
202 </configuration>
203 <executions>
204 <execution>
205 <id>jacoco-check</id>
206 <goals>
207 <goal>check</goal>
208 </goals>
209 <phase>test</phase>
210 <configuration>
211 <rules>
212 <rule implementation="org.jacoco.maven.RuleConfiguration">
213 <element>BUNDLE</element>
214 <limits>
215 <limit implementation="org.jacoco.report.check.Limit">
216 <counter>INSTRUCTION</counter>
217 <value>COVEREDRATIO</value>
218 <minimum>${jacoco-maven-plugin.coveredratio.minimum}</minimum>
219 </limit>
220 </limits>
221 </rule>
222 </rules>
223 </configuration>
224 </execution>
225 <execution>
226 <id>prepare-unit-tests</id>
227 <goals>
228 <goal>prepare-agent</goal>
229 </goals>
230 </execution>
231 <execution>
232 <id>report</id>
233 <phase>verify</phase>
234 <goals>
235 <goal>report</goal>
236 </goals>
237 </execution>
238 </executions>
239 </plugin>
JohnKeeneyf1e44602024-06-07 13:07:03 +0100240 </plugins>
JohnKeeneyf1e44602024-06-07 13:07:03 +0100241 </build>
242
JohnKeeneyf1e44602024-06-07 13:07:03 +0100243 <dependencies>
244 <dependency>
245 <groupId>junit</groupId>
246 <artifactId>junit</artifactId>
247 <scope>test</scope>
248 </dependency>
249 </dependencies>
250
251</project>