This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository 
https://gitbox.apache.org/repos/asf/sling-org-apache-sling-karaf-launchpad-oak-tar-integration-tests.git

commit d8ff93181bbfe96c9639b624c042b696b34aef5e
Author: Oliver Lietz <[email protected]>
AuthorDate: Wed Oct 4 13:17:05 2017 +0000

    SLING-7177 Switch to RepositoryInitializer factory configurations
    
    use RepositoryInitializer factory configurations
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1811068 
13f79535-47bb-0310-9956-ffa450edef68
---
 pom.xml                                            |  2 --
 .../SlingLaunchpadOakTarConfiguration.java         | 33 ++--------------------
 src/test/resources/repoinit.txt                    | 22 ---------------
 3 files changed, 3 insertions(+), 54 deletions(-)

diff --git a/pom.xml b/pom.xml
index f202669..c4adae2 100644
--- a/pom.xml
+++ b/pom.xml
@@ -38,7 +38,6 @@
   <properties>
     <org.apache.karaf.version>4.1.2</org.apache.karaf.version>
     <org.ops4j.pax.exam.version>4.11.0</org.ops4j.pax.exam.version>
-    
<repoinit.filename>${project.basedir}/src/test/resources/repoinit.txt</repoinit.filename>
   </properties>
 
   <scm>
@@ -236,7 +235,6 @@
             <configuration>
               
<configClass>org.apache.sling.karaf.tests.configuration.SlingLaunchpadOakTarConfiguration</configClass>
               <propagatedProperties>
-                repoinit.filename,
                 http.port
               </propagatedProperties>
             </configuration>
diff --git 
a/src/test/java/org/apache/sling/karaf/tests/configuration/SlingLaunchpadOakTarConfiguration.java
 
b/src/test/java/org/apache/sling/karaf/tests/configuration/SlingLaunchpadOakTarConfiguration.java
index 0634d6c..81daf54 100644
--- 
a/src/test/java/org/apache/sling/karaf/tests/configuration/SlingLaunchpadOakTarConfiguration.java
+++ 
b/src/test/java/org/apache/sling/karaf/tests/configuration/SlingLaunchpadOakTarConfiguration.java
@@ -18,47 +18,22 @@
  */
 package org.apache.sling.karaf.tests.configuration;
 
-import java.io.FileInputStream;
-import java.io.InputStream;
-
 import org.apache.sling.karaf.testing.KarafTestSupport;
 import org.ops4j.pax.exam.Configuration;
 import org.ops4j.pax.exam.Option;
 import org.ops4j.pax.exam.OptionUtils;
-import org.ops4j.pax.tinybundles.core.TinyBundles;
-import org.osgi.framework.Constants;
 
 import static org.ops4j.pax.exam.CoreOptions.cleanCaches;
 import static org.ops4j.pax.exam.CoreOptions.mavenBundle;
-import static org.ops4j.pax.exam.CoreOptions.streamBundle;
 import static 
org.ops4j.pax.exam.karaf.options.KarafDistributionOption.editConfigurationFilePut;
 
 public class SlingLaunchpadOakTarConfiguration extends KarafTestSupport {
 
-    private Option testBundle() throws Exception {
-        final String filename = System.getProperty("repoinit.filename");
-        final InputStream repoinit = new FileInputStream(filename);
-        return streamBundle(
-            TinyBundles.bundle()
-                .add("repoinit.txt", repoinit)
-                .set(Constants.BUNDLE_MANIFESTVERSION, "2")
-                .set(Constants.BUNDLE_SYMBOLICNAME, "repoinit")
-                .build()
-        ).start();
-    }
-
     @Configuration
     public Option[] configuration() throws Exception {
         final int httpPort = Integer.getInteger("http.port");
-        final String[] references = new String[]{
-            "raw:classpath://org.apache.sling.karaf-repoinit/sling.txt",
-            
"raw:classpath://org.apache.sling.karaf-repoinit/sling-discovery.txt",
-            "raw:classpath://org.apache.sling.karaf-repoinit/sling-event.txt",
-            "raw:classpath://org.apache.sling.karaf-repoinit/sling-i18n.txt",
-            
"raw:classpath://org.apache.sling.karaf-repoinit/sling-installer-jcr.txt",
-            
"raw:classpath://org.apache.sling.karaf-repoinit/sling-scripting.txt",
-            "raw:classpath://org.apache.sling.karaf-repoinit/sling-xss.txt",
-            "raw:classpath://repoinit/repoinit.txt"
+        final String[] scripts = new String[]{
+            "create path /repoinit/provisioningModelTest\ncreate service user 
provisioningModelUser"
         };
         return OptionUtils.combine(baseConfiguration(),
             cleanCaches(true),
@@ -70,7 +45,7 @@ public class SlingLaunchpadOakTarConfiguration extends 
KarafTestSupport {
             
editConfigurationFilePut("etc/org.apache.sling.servlets.resolver.SlingServletResolver.config",
 "servletresolver.cacheSize", "0"),
             
editConfigurationFilePut("etc/org.apache.sling.jcr.webdav.impl.servlets.SimpleWebDavServlet.config",
 "dav.root", "/dav"),
             
editConfigurationFilePut("etc/org.apache.sling.jcr.davex.impl.servlets.SlingDavExServlet.config",
 "alias", "/server"),
-            
editConfigurationFilePut("etc/org.apache.sling.jcr.repoinit.impl.RepositoryInitializer.config",
 "references", references),
+            
editConfigurationFilePut("etc/org.apache.sling.jcr.repoinit.RepositoryInitializer-test.config",
 "scripts", scripts),
             
editConfigurationFilePut("etc/org.apache.sling.jcr.base.internal.LoginAdminWhitelist.config",
 "whitelist.bypass", true),
             addSlingFeatures(
                 "sling-launchpad-oak-tar",
@@ -84,8 +59,6 @@ public class SlingLaunchpadOakTarConfiguration extends 
KarafTestSupport {
                 "sling-installer-provider-jcr",
                 "sling-jcr-jackrabbit-security"
             ),
-            // bundle for test (contains repoinit.txt)
-            testBundle(),
             // legacy
             
mavenBundle().groupId("org.apache.sling").artifactId("org.apache.sling.commons.json").versionAsInProject(),
             
mavenBundle().groupId("org.apache.sling").artifactId("org.apache.sling.servlets.compat").versionAsInProject(),
diff --git a/src/test/resources/repoinit.txt b/src/test/resources/repoinit.txt
deleted file mode 100644
index 172002f..0000000
--- a/src/test/resources/repoinit.txt
+++ /dev/null
@@ -1,22 +0,0 @@
-################################################################################
-#
-#    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.
-#
-################################################################################
-
-create path /repoinit/provisioningModelTest
-
-create service user provisioningModelUser

-- 
To stop receiving notification emails like this one, please contact
"[email protected]" <[email protected]>.

Reply via email to