summaryrefslogtreecommitdiffstats
path: root/java/sca/modules/node-impl-osgi/src/test/java/calculator
diff options
context:
space:
mode:
authorrfeng <rfeng@13f79535-47bb-0310-9956-ffa450edef68>2009-03-18 21:10:05 +0000
committerrfeng <rfeng@13f79535-47bb-0310-9956-ffa450edef68>2009-03-18 21:10:05 +0000
commit7188fa70c225d6b55ca6a02106ccf0f92eb1fc8e (patch)
tree4c9cad89d04e1f6ab9d355661b605ce4b53e283a /java/sca/modules/node-impl-osgi/src/test/java/calculator
parentcf01849798f2d842bcace2e6af657c0fa5ed094d (diff)
Access the equinox jars from a temporary maven repo @http://people.apache.org/~rfeng/repo/maven2
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@755736 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/sca/modules/node-impl-osgi/src/test/java/calculator')
-rw-r--r--java/sca/modules/node-impl-osgi/src/test/java/calculator/dosgi/test/CalculatorOSGiNodeTestCase.java8
-rw-r--r--java/sca/modules/node-impl-osgi/src/test/java/calculator/dosgi/test/CalculatorOSGiTestCase.java14
2 files changed, 5 insertions, 17 deletions
diff --git a/java/sca/modules/node-impl-osgi/src/test/java/calculator/dosgi/test/CalculatorOSGiNodeTestCase.java b/java/sca/modules/node-impl-osgi/src/test/java/calculator/dosgi/test/CalculatorOSGiNodeTestCase.java
index 86b0da3a01..dbb45dedb4 100644
--- a/java/sca/modules/node-impl-osgi/src/test/java/calculator/dosgi/test/CalculatorOSGiNodeTestCase.java
+++ b/java/sca/modules/node-impl-osgi/src/test/java/calculator/dosgi/test/CalculatorOSGiNodeTestCase.java
@@ -19,7 +19,6 @@
package calculator.dosgi.test;
-import java.io.File;
import java.lang.reflect.InvocationHandler;
import java.lang.reflect.Method;
import java.lang.reflect.Proxy;
@@ -80,13 +79,6 @@ public class CalculatorOSGiNodeTestCase {
}
Set<URL> bundles = new HashSet<URL>();
- File plugins = new File("target/test-classes/plugins");
- for (File f : plugins.listFiles()) {
- if (f.isFile()) {
- bundles.add(f.toURI().toURL());
- }
- }
-
if (client == null || client.booleanValue()) {
System.out.println("Generating calculator.dosgi bundle...");
bundles.add(OSGiTestBundles.createBundle("target/test-classes/calculator-bundle.jar",
diff --git a/java/sca/modules/node-impl-osgi/src/test/java/calculator/dosgi/test/CalculatorOSGiTestCase.java b/java/sca/modules/node-impl-osgi/src/test/java/calculator/dosgi/test/CalculatorOSGiTestCase.java
index 82204a0272..6ff261d01f 100644
--- a/java/sca/modules/node-impl-osgi/src/test/java/calculator/dosgi/test/CalculatorOSGiTestCase.java
+++ b/java/sca/modules/node-impl-osgi/src/test/java/calculator/dosgi/test/CalculatorOSGiTestCase.java
@@ -19,7 +19,6 @@
package calculator.dosgi.test;
-import java.io.File;
import java.lang.reflect.InvocationHandler;
import java.lang.reflect.Method;
import java.lang.reflect.Proxy;
@@ -62,13 +61,6 @@ public class CalculatorOSGiTestCase {
public static void setUpBeforeClass() throws Exception {
Set<URL> bundles = new HashSet<URL>();
- File plugins = new File("target/test-classes/plugins");
- for (File f : plugins.listFiles()) {
- if (f.isFile()) {
- bundles.add(f.toURI().toURL());
- }
- }
-
bundles.add(OSGiTestBundles.createBundle("target/test-classes/calculator-bundle.jar",
"calculator/dosgi/META-INF/MANIFEST.MF",
new String[][] {
@@ -103,10 +95,14 @@ public class CalculatorOSGiTestCase {
DivideService.class,
DivideServiceImpl.class));
try {
- host = new EquinoxHost(bundles);
+ host = new EquinoxHost();
BundleContext context = host.start();
+ for (URL loc : bundles) {
+ host.installBundle(loc, null);
+ }
for (Bundle b : context.getBundles()) {
if (b.getSymbolicName().equals("org.eclipse.equinox.ds")) {
+ System.out.println(string(b, false));
b.start();
System.out.println(string(b, false));
}