You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by ss...@apache.org on 2016/09/08 12:54:03 UTC

svn commit: r1759803 - in /sling/trunk/bundles/extensions/resourcebuilder: .gitignore impl/ integration-tests/ pom.xml src/

Author: sseifert
Date: Thu Sep  8 12:54:03 2016
New Revision: 1759803

URL: http://svn.apache.org/viewvc?rev=1759803&view=rev
Log:
SLING-6040 revert last two commits rev. 1759507, 1759545 - there is a better solution

Added:
    sling/trunk/bundles/extensions/resourcebuilder/.gitignore
      - copied unchanged from r1759506, sling/trunk/bundles/extensions/resourcebuilder/.gitignore
    sling/trunk/bundles/extensions/resourcebuilder/src/
      - copied from r1759506, sling/trunk/bundles/extensions/resourcebuilder/src/
Removed:
    sling/trunk/bundles/extensions/resourcebuilder/impl/
    sling/trunk/bundles/extensions/resourcebuilder/integration-tests/
Modified:
    sling/trunk/bundles/extensions/resourcebuilder/pom.xml

Modified: sling/trunk/bundles/extensions/resourcebuilder/pom.xml
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/resourcebuilder/pom.xml?rev=1759803&r1=1759802&r2=1759803&view=diff
==============================================================================
--- sling/trunk/bundles/extensions/resourcebuilder/pom.xml (original)
+++ sling/trunk/bundles/extensions/resourcebuilder/pom.xml Thu Sep  8 12:54:03 2016
@@ -27,35 +27,229 @@
         <relativePath/>
     </parent>
 
-    <artifactId>org.apache.sling.resourcebuilder.reactor</artifactId>
-    <packaging>pom</packaging>
+    <artifactId>org.apache.sling.resourcebuilder</artifactId>
     <version>0.0.1-SNAPSHOT</version>
-    <name>Apache Sling Resource Builder Reactor</name>
+    <packaging>bundle</packaging>
+
+    <name>Apache Sling Resource Builder</name>
     <description>Utilities to create Sling content</description>
 
+    <properties>
+        <!-- Set this to run the server on a specific port
+        <http.port></http.port>
+         -->
+         
+        <!-- Set this to run tests against an existing server instance -->
+        <keepJarRunning>false</keepJarRunning>
+        
+        <!-- 
+            Options for the VM that executes our runnable jar. 
+            Set debugging options here to debug teleported tests.  
+        -->
+        <jar.executor.vm.options>-Xmx512m</jar.executor.vm.options>
+        
+         <!-- Options for the jar to execute. $JAREXEC_SERVER_PORT$ is replaced by the
+            selected port number -->
+        <jar.executor.jar.options>-p $JAREXEC_SERVER_PORT$</jar.executor.jar.options>
+    </properties>
     <scm>
-        <connection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/bundles/extensions/resourcebuilder</connection>
-        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/bundles/extensions/resourcebuilder</developerConnection>
-        <url>https://svn.apache.org/repos/asf/sling/trunk/bundles/extensions/resourcebuilder</url>
+        <connection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/bundles/commons/resourcebuilder</connection>
+        <developerConnection>scm:svn:https://svn.apache.org/repos/asf/sling/trunk/bundles/commons/resourcebuilder</developerConnection>
+        <url>https://svn.apache.org/repos/asf/sling/trunk/bundles/commons/resourcebuilder</url>
     </scm>
-  
+    
     <build>
         <plugins>
             <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+                <extensions>true</extensions>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-scr-plugin</artifactId>
+            </plugin>
+            <plugin>
                 <groupId>org.apache.rat</groupId>
                 <artifactId>apache-rat-plugin</artifactId>
                 <configuration>
                     <excludes>
+                        <exclude>src/test/resources/**</exclude>
                         <exclude>sling/**</exclude>
                     </excludes>
                 </configuration>
             </plugin>
-        </plugins>
+            <plugin>
+                <!-- Find free ports to run our server -->
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>build-helper-maven-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>reserve-server-port</id>
+                        <goals>
+                            <goal>reserve-network-port</goal>
+                        </goals>
+                        <phase>process-resources</phase>
+                        <configuration>
+                            <portNames>
+                                <portName>http.port</portName>
+                            </portNames>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+            <plugin>
+                <artifactId>maven-clean-plugin</artifactId>
+                <configuration>
+                    <filesets>
+                        <fileset>
+                            <directory>${basedir}</directory>
+                            <includes>
+                                <!-- sling folder is the workdir of the executable jar that we test -->
+                                <include>sling/**</include>
+                            </includes>
+                        </fileset>
+                    </filesets>
+                </configuration>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-failsafe-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>integration-test</id>
+                        <goals>
+                            <goal>integration-test</goal>
+                        </goals>
+                    </execution>
+                    <execution>
+                        <id>verify</id>
+                        <goals>
+                            <goal>verify</goal>
+                        </goals>
+                    </execution>
+                </executions>
+                <configuration>
+                    <systemPropertyVariables>
+                        <!--  these are the minimal options required for the jar executor, see bundle-with-it module for more -->
+                        <keepJarRunning>${keepJarRunning}</keepJarRunning>
+                        <jar.executor.jar.options>${jar.executor.jar.options}</jar.executor.jar.options>
+                        <jar.executor.vm.options>${jar.executor.vm.options}</jar.executor.vm.options>
+                        <jar.executor.server.port>${http.port}</jar.executor.server.port>
+                        <additional.bundles.path>${project.build.directory}</additional.bundles.path>
+                        <server.ready.path.1>/:script src="system/sling.js"</server.ready.path.1>
+                        <server.ready.path.2>/.explorer.html:href="/libs/sling/explorer/css/explorer.css"</server.ready.path.2>
+                        <server.ready.path.3>/sling-test/sling/sling-test.html:Sling client library tests</server.ready.path.3>
+                        
+                        <!-- Additional bundles to install for testing -->
+                        <sling.additional.bundle.1>org.apache.sling.junit.core</sling.additional.bundle.1>
+                        <sling.additional.bundle.2>${project.artifactId}-${project.version}.jar</sling.additional.bundle.2>
+                    </systemPropertyVariables>
+                </configuration>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-dependency-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>copy-runnable-jar</id>
+                        <goals>
+                            <goal>copy-dependencies</goal>
+                        </goals>
+                            <phase>process-resources</phase>
+                        <configuration>
+                            <includeArtifactIds>org.apache.sling.launchpad</includeArtifactIds>
+                            <excludeTransitive>true</excludeTransitive>
+                            <overWriteReleases>false</overWriteReleases>
+                            <overWriteSnapshots>false</overWriteSnapshots>
+                        </configuration>
+                    </execution>
+                    <execution>
+                        <!-- 
+                            Consider all dependencies as candidates to be installed
+                            as additional bundles. We use system properties to define
+                            which bundles to install in which order.  
+                        -->
+                        <id>copy-additional-bundles</id>
+                        <goals>
+                            <goal>copy-dependencies</goal>
+                        </goals>
+                            <phase>process-resources</phase>
+                        <configuration>
+                            <outputDirectory>${project.build.directory}</outputDirectory>
+                            <excludeTransitive>true</excludeTransitive>
+                            <overWriteReleases>false</overWriteReleases>
+                            <overWriteSnapshots>false</overWriteSnapshots>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+         </plugins>
     </build>
 
-    <modules>
-        <module>impl</module>
-        <module>integration-tests</module>
-    </modules>
+    <dependencies>
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-simple</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.sling</groupId>
+            <artifactId>org.apache.sling.api</artifactId>
+            <version>2.3.0</version>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.sling</groupId>
+            <artifactId>org.apache.sling.commons.mime</artifactId>
+            <version>2.1.2</version>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>commons-io</groupId>
+            <artifactId>commons-io</artifactId>
+            <version>2.4</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.sling</groupId>
+            <artifactId>org.apache.sling.testing.sling-mock</artifactId>
+            <version>1.6.0</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.sling</groupId>
+            <artifactId>org.apache.sling.junit.core</artifactId>
+            <version>1.0.14</version>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.sling</groupId>
+            <artifactId>org.apache.sling.testing.tools</artifactId>
+            <version>1.0.10</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.sling</groupId>
+            <artifactId>org.apache.sling.junit.teleporter</artifactId>
+            <!-- SNAPSHOT required due to SLING-5712 -->
+            <version>1.0.7-SNAPSHOT</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.sling</groupId>
+            <artifactId>org.apache.sling.launchpad</artifactId>
+            <version>8</version>
+            <scope>provided</scope>
+        </dependency>
+    </dependencies>
 
 </project>