You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicemix.apache.org by gn...@apache.org on 2009/02/20 21:02:36 UTC

svn commit: r746354 - /servicemix/smx4/kernel/trunk/testing/support/src/main/java/org/apache/servicemix/kernel/testing/support/SmxKernelPlatform.java

Author: gnodet
Date: Fri Feb 20 20:02:36 2009
New Revision: 746354

URL: http://svn.apache.org/viewvc?rev=746354&view=rev
Log:
Fix integation tests support

Modified:
    servicemix/smx4/kernel/trunk/testing/support/src/main/java/org/apache/servicemix/kernel/testing/support/SmxKernelPlatform.java

Modified: servicemix/smx4/kernel/trunk/testing/support/src/main/java/org/apache/servicemix/kernel/testing/support/SmxKernelPlatform.java
URL: http://svn.apache.org/viewvc/servicemix/smx4/kernel/trunk/testing/support/src/main/java/org/apache/servicemix/kernel/testing/support/SmxKernelPlatform.java?rev=746354&r1=746353&r2=746354&view=diff
==============================================================================
--- servicemix/smx4/kernel/trunk/testing/support/src/main/java/org/apache/servicemix/kernel/testing/support/SmxKernelPlatform.java (original)
+++ servicemix/smx4/kernel/trunk/testing/support/src/main/java/org/apache/servicemix/kernel/testing/support/SmxKernelPlatform.java Fri Feb 20 20:02:36 2009
@@ -40,6 +40,7 @@
 import org.springframework.util.ClassUtils;
 import org.apache.felix.framework.Felix;
 import org.apache.felix.framework.util.CompoundEnumeration;
+import org.apache.felix.framework.util.FelixConstants;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 import org.apache.servicemix.kernel.main.Main;
@@ -130,16 +131,19 @@
         List<BundleActivator> activations = new ArrayList<BundleActivator>();
         activations.add(activator);
 
+        Properties props = getConfigurationProperties();
+        props.put(FelixConstants.SYSTEMBUNDLE_ACTIVATORS_PROP, activations);
+
         Thread.currentThread().setContextClassLoader(classLoader);
         Class cl = classLoader.loadClass(Felix.class.getName());
-        Constructor cns = cl.getConstructor(Map.class, List.class);
-        platform = cns.newInstance(getConfigurationProperties(), activations);
+        Constructor cns = cl.getConstructor(Map.class);
+        platform = cns.newInstance(props);
         platform.getClass().getMethod("start").invoke(platform);
 
         Bundle systemBundle = (Bundle) platform;
 
         // call getBundleContext
-        final Method getContext = systemBundle.getClass().getDeclaredMethod("getBundleContext", null);
+        final Method getContext = systemBundle.getClass().getMethod("getBundleContext", null);
 
         AccessController.doPrivileged(new PrivilegedAction() {