| <?xml version="1.0" encoding="UTF-8"?> |
| <!-- |
| Licensed to the Apache Software Foundation (ASF) under one or |
| more contributor license agreements. See the NOTICE file |
| distributed with this work for additional information regarding |
| copyright ownership. The ASF licenses this file to you under the |
| Apache License, Version 2.0 (the "License"); you may not use |
| this file except in compliance with the License. You may obtain |
| a copy of the License at |
| |
| http://www.apache.org/licenses/LICENSE-2.0 Unless required by |
| applicable law or agreed to in writing, software distributed |
| under the License is distributed on an "AS IS" BASIS, WITHOUT |
| WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| See the License for the specific language governing permissions |
| and limitations under the License. |
| --> |
| <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/maven-v4_0_0.xsd"> |
| |
| <modelVersion>4.0.0</modelVersion> |
| <parent> |
| <groupId>org.apache.sling</groupId> |
| <artifactId>sling</artifactId> |
| <version>38</version> |
| <relativePath/> |
| </parent> |
| |
| <artifactId>org.apache.sling.installer.it</artifactId> |
| <version>3.11.5-SNAPSHOT</version> |
| <packaging>jar</packaging> |
| |
| <name>Apache Sling Installer Integration Tests</name> |
| <description>Integration tests of the Sling installer bundle</description> |
| |
| <properties> |
| <exam.version>4.13.1</exam.version> |
| <url.version>2.6.1</url.version> |
| <pax.exam.log.level>INFO</pax.exam.log.level> |
| <pax.vm.options>-Xmx256M -XX:MaxPermSize=256m</pax.vm.options> |
| <installer.configuration.version>1.3.1-SNAPSHOT</installer.configuration.version> |
| |
| <argLine>${pax.vm.options}</argLine> |
| |
| <!-- BundleInstallStressTest parameters --> |
| <BundleInstallStressTest.default.bundles.folder>${project.build.directory}/bundle-install-stress-test-bundles</BundleInstallStressTest.default.bundles.folder> |
| <osgi.installer.BundleInstallStressTest.bundles.folder>${BundleInstallStressTest.default.bundles.folder}</osgi.installer.BundleInstallStressTest.bundles.folder> |
| <osgi.installer.BundleInstallStressTest.cycle.count>10</osgi.installer.BundleInstallStressTest.cycle.count> |
| <osgi.installer.BundleInstallStressTest.expect.timeout.seconds>30</osgi.installer.BundleInstallStressTest.expect.timeout.seconds> |
| </properties> |
| |
| <scm> |
| <connection>scm:git:https://gitbox.apache.org/repos/asf/sling-org-apache-sling-installer-it.git</connection> |
| <developerConnection>scm:git:https://gitbox.apache.org/repos/asf/sling-org-apache-sling-installer-it.git</developerConnection> |
| <url>https://gitbox.apache.org/repos/asf?p=sling-org-apache-sling-installer-it.git</url> |
| </scm> |
| |
| <build> |
| <plugins> |
| <plugin> |
| <groupId>org.apache.rat</groupId> |
| <artifactId>apache-rat-plugin</artifactId> |
| <configuration> |
| <excludes> |
| <exclude>src/test/resources/blacklisttest/sling_bootstrap.txt</exclude> |
| <exclude>src/test/resources/blacklisttestempty/sling_bootstrap.txt</exclude> |
| <exclude>src/test/resources/sling_bootstrap.txt</exclude> |
| </excludes> |
| </configuration> |
| </plugin> |
| <plugin> |
| <groupId>org.apache.maven.plugins</groupId> |
| <artifactId>maven-surefire-plugin</artifactId> |
| <configuration> |
| <systemProperties> |
| <property> |
| <name>pax.exam.log.level</name> |
| <value>${pax.exam.log.level}</value> |
| </property> |
| <property> |
| <name>pax.exam.debug.port</name> |
| <value>${pax.exam.debug.port}</value> |
| </property> |
| <property> |
| <name>osgi.installer.pom.version</name> |
| <value>${project.version}</value> |
| </property> |
| <property> |
| <name>installer.configuration.version</name> |
| <value>${installer.configuration.version}</value> |
| </property> |
| <property> |
| <name>osgi.installer.base.dir</name> |
| <value>${project.build.directory}</value> |
| </property> |
| <property> |
| <name>osgi.installer.BundleInstallStressTest.bundles.folder</name> |
| <value>${osgi.installer.BundleInstallStressTest.bundles.folder}</value> |
| </property> |
| <property> |
| <name>osgi.installer.BundleInstallStressTest.cycle.count</name> |
| <value>${osgi.installer.BundleInstallStressTest.cycle.count}</value> |
| </property> |
| <property> |
| <name>osgi.installer.BundleInstallStressTest.expect.timeout.seconds</name> |
| <value>${osgi.installer.BundleInstallStressTest.expect.timeout.seconds}</value> |
| </property> |
| </systemProperties> |
| </configuration> |
| </plugin> |
| <plugin> |
| <groupId>org.apache.maven.plugins</groupId> |
| <artifactId>maven-dependency-plugin</artifactId> |
| <executions> |
| <execution> |
| <id>copy-test-bundles</id> |
| <goals> |
| <goal>copy-dependencies</goal> |
| </goals> |
| <configuration> |
| <outputDirectory>${project.build.directory}/testbundles</outputDirectory> |
| <excludeTransitive>true</excludeTransitive> |
| <includeArtifactIds>org.apache.felix.webconsole</includeArtifactIds> |
| </configuration> |
| </execution> |
| </executions> |
| </plugin> |
| <plugin> |
| <!-- |
| Create several simple test bundles with different version |
| numbers, to test install/upgrade operations. |
| --> |
| <artifactId>maven-antrun-plugin</artifactId> |
| <executions> |
| <execution> |
| <id>testbundle-1.0</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create testbundle 1.0"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-testbundle-1.0.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| <attribute name="Bundle-Name" value="OSGi controller test bundle" /> |
| <attribute name="Bundle-SymbolicName" value="osgi-installer-testbundle" /> |
| <attribute name="Bundle-Version" value="1.0" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>testbundle-1.1</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create testbundle 1.1"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-testbundle-1.1.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| <attribute name="Bundle-Name" value="OSGi controller test bundle" /> |
| <attribute name="Bundle-SymbolicName" value="osgi-installer-testbundle" /> |
| <attribute name="Bundle-Version" value="1.1" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>testbundle-1.2</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create testbundle 1.2"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-testbundle-1.2.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| <attribute name="Bundle-Name" value="OSGi controller test bundle" /> |
| <attribute name="Bundle-SymbolicName" value="osgi-installer-testbundle" /> |
| <attribute name="Bundle-Version" value="1.2" /> |
| <attribute name="Export-Package" value="com.example.testbundle.somepackage" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>testA-1.0</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create testA bundle 1.0"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-testA-1.0.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| <attribute name="Bundle-Name" value="OSGi controller test bundle" /> |
| <attribute name="Bundle-SymbolicName" value="osgi-installer-testA" /> |
| <attribute name="Bundle-Version" value="1.0" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>testB-1.0</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create testB bundle 1.0"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-testB-1.0.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="**/a/**" /> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| <attribute name="Bundle-Name" value="OSGi controller test bundle" /> |
| <attribute name="Bundle-SymbolicName" value="osgi-installer-testB" /> |
| <attribute name="Export-Package" value="org.apache.sling.installer.it.a;version="1.0"" /> |
| <attribute name="Bundle-Version" value="1.0" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>needsB-1.0</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create needsB bundle"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-needsB.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="**/b/**" /> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| <attribute name="Bundle-Name" value="OSGi controller test bundle" /> |
| <attribute name="Bundle-SymbolicName" value="osgi-installer-needsB" /> |
| <attribute name="Bundle-Version" value="1.0" /> |
| <attribute name="Import-Package" value="org.apache.sling.installer.it.a;version="1.0"" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>snapshota-1.0</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create snap bundle"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-snap.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="**/b/**" /> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| <attribute name="Bundle-Name" value="OSGi controller test bundle" /> |
| <attribute name="Bundle-SymbolicName" value="osgi-installer-snapshot-test" /> |
| <!-- |
| Need to use OSGi-compliant version, so .SNAPSHOT not -SNAPSHOT. |
| In real bundles, bnd and similar tools to the conversion. |
| --> |
| <attribute name="Bundle-Version" value="1.0.0.SNAPSHOT" /> |
| <attribute name="SNAPSHOT" value="A" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>snapshotb-1.0</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create snapb bundle"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-snapb.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="**/b/**" /> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| <attribute name="Bundle-Name" value="OSGi controller test bundle" /> |
| <attribute name="Bundle-SymbolicName" value="osgi-installer-snapshot-test" /> |
| <!-- |
| Need to use OSGi-compliant version, so .SNAPSHOT not -SNAPSHOT. |
| In real bundles, bnd and similar tools to the conversion. |
| --> |
| <attribute name="Bundle-Version" value="1.0.0.SNAPSHOT" /> |
| <attribute name="SNAPSHOT" value="B" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>snapshotc-1.0</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create snapc bundle"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-snapc.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="**/b/**" /> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| <attribute name="Bundle-Name" value="OSGi controller test bundle" /> |
| <attribute name="Bundle-SymbolicName" value="osgi-installer-snapshot-test" /> |
| <!-- |
| Need to use OSGi-compliant version, so .SNAPSHOT not -SNAPSHOT. |
| In real bundles, bnd and similar tools to the conversion. |
| --> |
| <attribute name="Bundle-Version" value="1.0.0.SNAPSHOT" /> |
| <attribute name="SNAPSHOT" value="C" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>missing-headers</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create snapc bundle"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-notabundle.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>fragmentA-1.0</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create fragment bundle 1.0"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-testfragment-1.0.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| <attribute name="Bundle-Name" value="OSGi controller test fragment bundle" /> |
| <attribute name="Fragment-Host" value="osgi-installer-testbundle" /> |
| <attribute name="Bundle-Version" value="1.0" /> |
| <attribute name="Bundle-SymbolicName" value="osgi-installer-testfragment" /> |
| <attribute name="Export-Package" value="com.example.testfragment.fragmentpackage" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>invalid-version</id> |
| <phase>compile</phase> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| <configuration> |
| <tasks name="Create invalid-version bundle"> |
| <jar destfile="${project.build.directory}/${project.artifactId}-${project.version}-invalid-version.jar"> |
| <fileset dir="${project.build.directory}/classes"> |
| <include name="META-INF/**" /> |
| </fileset> |
| <manifest> |
| <attribute name="Bundle-ManifestVersion" value="2" /> |
| <attribute name="Bundle-Name" value="OSGi controller test bundle, invalid version number" /> |
| <attribute name="Bundle-SymbolicName" value="osgi-installer-invalid-version-test" /> |
| <!-- |
| Use -SNAPSHOT to make bundle version number invalid. |
| In real bundles, bnd and similar tools do the conversion to |
| valid version strings. |
| --> |
| <attribute name="Bundle-Version" value="1.0.0-SNAPSHOT" /> |
| </manifest> |
| </jar> |
| </tasks> |
| </configuration> |
| </execution> |
| <execution> |
| <id>create-test-bundles</id> |
| <phase>test-compile</phase> |
| <configuration> |
| <tasks> |
| <!-- Copy a set of distinct valid bundles for the BundleInstallStressTest --> |
| <mkdir dir="${BundleInstallStressTest.default.bundles.folder}" /> |
| <copy todir="${BundleInstallStressTest.default.bundles.folder}"> |
| <fileset dir="${project.build.directory}"> |
| <include name="*testbundle-1.2.jar" /> |
| <include name="*testB-1.0.jar" /> |
| <include name="*testA-1.0.jar" /> |
| <include name="*needsB.jar" /> |
| <include name="*testfragment-1.0.jar" /> |
| </fileset> |
| </copy> |
| </tasks> |
| </configuration> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| </execution> |
| </executions> |
| </plugin> |
| </plugins> |
| </build> |
| |
| <dependencies> |
| <dependency> |
| <groupId>org.osgi</groupId> |
| <artifactId>org.osgi.service.cm</artifactId> |
| <version>1.6.0</version> |
| <scope>provided</scope> |
| </dependency> |
| <dependency> |
| <groupId>org.apache.sling</groupId> |
| <artifactId>org.apache.sling.installer.factory.configuration</artifactId> |
| <version>${installer.configuration.version}</version> |
| <scope>provided</scope> |
| </dependency> |
| <dependency> |
| <groupId>org.apache.sling</groupId> |
| <artifactId>org.apache.sling.installer.core</artifactId> |
| <version>${project.version}</version> |
| <scope>provided</scope> |
| </dependency> |
| <dependency> |
| <groupId>org.apache.sling</groupId> |
| <artifactId>org.apache.sling.commons.log</artifactId> |
| <version>2.1.2</version> |
| <scope>provided</scope> |
| </dependency> |
| <dependency> |
| <groupId>junit</groupId> |
| <artifactId>junit</artifactId> |
| <version>4.13</version> |
| </dependency> |
| <dependency> |
| <groupId>org.ops4j.pax.exam</groupId> |
| <artifactId>pax-exam-container-native</artifactId> |
| <version>${exam.version}</version> |
| <scope>test</scope> |
| </dependency> |
| <dependency> |
| <groupId>org.ops4j.pax.exam</groupId> |
| <artifactId>pax-exam-junit4</artifactId> |
| <version>${exam.version}</version> |
| <scope>test</scope> |
| </dependency> |
| <dependency> |
| <groupId>org.ops4j.pax.exam</groupId> |
| <artifactId>pax-exam-link-mvn</artifactId> |
| <version>${exam.version}</version> |
| <scope>test</scope> |
| </dependency> |
| <dependency> |
| <groupId>org.ops4j.pax.url</groupId> |
| <artifactId>pax-url-aether</artifactId> |
| <version>${url.version}</version> |
| <scope>test</scope> |
| </dependency> |
| <dependency> |
| <groupId>javax.inject</groupId> |
| <artifactId>javax.inject</artifactId> |
| <scope>test</scope> |
| </dependency> |
| <dependency> |
| <groupId>org.apache.felix</groupId> |
| <artifactId>org.apache.felix.framework</artifactId> |
| <version>6.0.3</version> |
| <scope>test</scope> |
| </dependency> |
| </dependencies> |
| </project> |