66b4bde8d160b9e6274970aa3d5260b92b34742b
[controller.git] / opendaylight / md-sal / mdsal-it-parent / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!-- vi: set et smarttab sw=4 tabstop=4: -->
3 <!--
4 Copyright (c) 2014 Cisco Systems, Inc. and others.  All rights reserved.
5
6 This program and the accompanying materials are made available under the
7 terms of the Eclipse Public License v1.0 which accompanies this distribution,
8 and is available at http://www.eclipse.org/legal/epl-v10.html
9 -->
10 <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">
11   <modelVersion>4.0.0</modelVersion>
12
13   <parent>
14     <groupId>org.opendaylight.odlparent</groupId>
15     <artifactId>bundle-parent</artifactId>
16     <version>7.0.6</version>
17     <relativePath/>
18   </parent>
19
20   <groupId>org.opendaylight.controller</groupId>
21   <artifactId>mdsal-it-parent</artifactId>
22   <version>2.0.5-SNAPSHOT</version>
23   <packaging>pom</packaging>
24
25   <properties>
26     <karaf.distro.groupId>org.opendaylight.odlparent</karaf.distro.groupId>
27     <karaf.distro.artifactId>opendaylight-karaf-empty</karaf.distro.artifactId>
28     <karaf.distro.type>zip</karaf.distro.type>
29     <karaf.keep.unpack>false</karaf.keep.unpack>
30   </properties>
31
32   <dependencyManagement>
33     <dependencies>
34       <dependency>
35         <groupId>org.opendaylight.controller</groupId>
36         <artifactId>controller-artifacts</artifactId>
37         <version>2.0.5-SNAPSHOT</version>
38         <type>pom</type>
39         <scope>import</scope>
40       </dependency>
41     </dependencies>
42   </dependencyManagement>
43
44   <dependencies>
45     <dependency>
46       <groupId>org.opendaylight.controller</groupId>
47       <artifactId>mdsal-it-base</artifactId>
48     </dependency>
49
50     <!-- Dependencies for pax exam karaf container -->
51     <dependency>
52         <groupId>org.ops4j.pax.exam</groupId>
53         <artifactId>pax-exam-container-karaf</artifactId>
54     </dependency>
55     <dependency>
56         <groupId>org.ops4j.pax.exam</groupId>
57         <artifactId>pax-exam-junit4</artifactId>
58     </dependency>
59     <dependency>
60         <groupId>org.ops4j.pax.exam</groupId>
61         <artifactId>pax-exam</artifactId>
62     </dependency>
63     <dependency>
64         <groupId>org.ops4j.pax.exam</groupId>
65         <artifactId>pax-exam-features</artifactId>
66         <type>xml</type>
67     </dependency>
68     <dependency>
69         <groupId>org.ops4j.pax.exam</groupId>
70         <artifactId>pax-exam-extender-service</artifactId>
71     </dependency>
72     <dependency>
73         <groupId>org.ops4j.pax.exam</groupId>
74         <artifactId>pax-exam-inject</artifactId>
75     </dependency>
76     <dependency>
77         <groupId>org.ops4j.pax.exam</groupId>
78         <artifactId>pax-exam-invoker-junit</artifactId>
79     </dependency>
80     <dependency>
81         <groupId>org.ops4j.pax.url</groupId>
82         <artifactId>pax-url-aether</artifactId>
83     </dependency>
84     <dependency>
85         <groupId>org.apache.karaf.features</groupId>
86         <artifactId>org.apache.karaf.features.core</artifactId>
87         <version>${karaf.version}</version>
88     </dependency>
89     <dependency>
90         <groupId>org.osgi</groupId>
91         <artifactId>org.osgi.core</artifactId>
92     </dependency>
93     <dependency>
94         <groupId>junit</groupId>
95         <artifactId>junit</artifactId>
96     </dependency>
97
98     <!-- Testing Dependencies -->
99     <dependency>
100       <groupId>org.mockito</groupId>
101       <artifactId>mockito-core</artifactId>
102       <scope>test</scope>
103     </dependency>
104   </dependencies>
105   <build>
106     <plugins>
107       <plugin>
108           <artifactId>maven-surefire-plugin</artifactId>
109               <!-- Overridden to have TCP channel support -->
110           <version>3.0.0-M5</version>
111           <configuration>
112               <!-- Overridden to fix corruption, where the process would hang after test -->
113               <forkNode implementation="org.apache.maven.plugin.surefire.extensions.SurefireForkNodeFactory"/>
114               <systemPropertyVariables>
115                 <!-- CONTROLLER-1799: Use the same repository for Pax Exam as is used for Maven -->
116                 <org.ops4j.pax.url.mvn.localRepository>${settings.localRepository}</org.ops4j.pax.url.mvn.localRepository>
117               </systemPropertyVariables>
118           </configuration>
119       </plugin>
120       <plugin>
121         <groupId>org.apache.maven.plugins</groupId>
122         <artifactId>maven-failsafe-plugin</artifactId>
123         <executions>
124           <execution>
125             <goals>
126               <goal>integration-test</goal>
127               <goal>verify</goal>
128             </goals>
129             <configuration>
130               <systemProperties>
131                 <property>
132                  <name>karaf.distro.groupId</name>
133                  <value>${karaf.distro.groupId}</value>
134                 </property>
135                 <property>
136                  <name>karaf.distro.artifactId</name>
137                  <value>${karaf.distro.artifactId}</value>
138                 </property>
139                 <property>
140                  <name>karaf.distro.version</name>
141                  <value>${karaf.distro.version}</value>
142                 </property>
143                 <property>
144                  <name>karaf.distro.type</name>
145                  <value>${karaf.distro.type}</value>
146                 </property>
147                 <property>
148                  <name>karaf.keep.unpack</name>
149                  <value>${karaf.keep.unpack}</value>
150                 </property>
151               </systemProperties>
152               <reportsDirectory>${project.build.directory}/surefire-reports</reportsDirectory>
153             </configuration>
154           </execution>
155         </executions>
156       </plugin>
157       <!-- Needed if you use versionAsInProject() -->
158       <plugin>
159           <groupId>org.apache.servicemix.tooling</groupId>
160           <artifactId>depends-maven-plugin</artifactId>
161           <executions>
162               <execution>
163                   <id>generate-depends-file</id>
164                   <goals>
165                       <goal>generate-depends-file</goal>
166                   </goals>
167               </execution>
168           </executions>
169       </plugin>
170
171       <!-- Copy the Base Test classes into test-classes so they can become available in the karaf container -->
172       <plugin>
173         <groupId>org.apache.maven.plugins</groupId>
174         <artifactId>maven-dependency-plugin</artifactId>
175         <executions>
176           <execution>
177            <id>unpack-karaf-resources</id>
178            <goals>
179             <goal>unpack-dependencies</goal>
180            </goals>
181            <phase>process-test-resources</phase>
182            <configuration>
183             <outputDirectory>${project.build.directory}/test-classes</outputDirectory>
184             <groupId>org.opendaylight.controller</groupId>
185             <includeArtifactIds>mockito-core,objenesis,mdsal-it-base</includeArtifactIds>
186             <excludes>META-INF\/**</excludes>
187             <ignorePermissions>false</ignorePermissions>
188            </configuration>
189           </execution>
190          </executions>
191       </plugin>
192     </plugins>
193   </build>
194 </project>