Author: rombert
Date: Tue Apr 30 23:17:37 2013
New Revision: 1477870

URL: http://svn.apache.org/r1477870
Log:
SLING-2847 : Installer integration tests fail due to unresolvable
artifacts

Since pax-exam does not support the maven.repo.local system property,
add support for it in OsgiInstallerTestBase.

Modified:
    
sling/trunk/installer/it/src/test/java/org/apache/sling/installer/it/OsgiInstallerTestBase.java

Modified: 
sling/trunk/installer/it/src/test/java/org/apache/sling/installer/it/OsgiInstallerTestBase.java
URL: 
http://svn.apache.org/viewvc/sling/trunk/installer/it/src/test/java/org/apache/sling/installer/it/OsgiInstallerTestBase.java?rev=1477870&r1=1477869&r2=1477870&view=diff
==============================================================================
--- 
sling/trunk/installer/it/src/test/java/org/apache/sling/installer/it/OsgiInstallerTestBase.java
 (original)
+++ 
sling/trunk/installer/it/src/test/java/org/apache/sling/installer/it/OsgiInstallerTestBase.java
 Tue Apr 30 23:17:37 2013
@@ -24,6 +24,7 @@ import static org.ops4j.pax.exam.CoreOpt
 import static org.ops4j.pax.exam.CoreOptions.options;
 import static org.ops4j.pax.exam.CoreOptions.provision;
 import static org.ops4j.pax.exam.CoreOptions.systemProperty;
+import static org.ops4j.pax.exam.CoreOptions.when;
 
 import java.io.File;
 import java.io.FileInputStream;
@@ -39,6 +40,7 @@ import javax.inject.Inject;
 
 import org.apache.sling.installer.api.InstallableResource;
 import org.apache.sling.installer.api.OsgiInstaller;
+import org.ops4j.pax.exam.CoreOptions;
 import org.ops4j.pax.exam.Option;
 import org.osgi.framework.Bundle;
 import org.osgi.framework.BundleContext;
@@ -391,8 +393,13 @@ class OsgiInstallerTestBase implements F
                vmOpt += " 
-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=" + paxDebugPort;
        }
 
+       String localRepo = System.getProperty("maven.repo.local", "");
+
        return options(
                 junitBundles(),
+                when( localRepo.length() > 0 ).useOptions(
+                        
systemProperty("org.ops4j.pax.url.mvn.localRepository").value(localRepo)
+                ),
                 systemProperty( 
"org.ops4j.pax.logging.DefaultServiceLog.level" ).value(paxDebugLevel),
                 provision(
                            mavenBundle("org.apache.felix", 
"org.apache.felix.scr", "1.6.0"),


Reply via email to