karaf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cschnei...@apache.org
Subject [2/2] karaf git commit: Fix itests by adding Bundle-ManifestVersion:2
Date Mon, 27 Jun 2016 10:25:07 GMT
Fix itests by adding Bundle-ManifestVersion:2


Project: http://git-wip-us.apache.org/repos/asf/karaf/repo
Commit: http://git-wip-us.apache.org/repos/asf/karaf/commit/9e0d667f
Tree: http://git-wip-us.apache.org/repos/asf/karaf/tree/9e0d667f
Diff: http://git-wip-us.apache.org/repos/asf/karaf/diff/9e0d667f

Branch: refs/heads/karaf-4.0.x
Commit: 9e0d667f86020314870e40659cedd857e15d0430
Parents: f9a5082
Author: Christian Schneider <chris@die-schneider.net>
Authored: Mon Jun 27 12:23:48 2016 +0200
Committer: Christian Schneider <chris@die-schneider.net>
Committed: Mon Jun 27 12:24:58 2016 +0200

----------------------------------------------------------------------
 .../org/apache/karaf/itests/ImportServiceTest.java  | 16 ++++++++++------
 1 file changed, 10 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/karaf/blob/9e0d667f/itests/src/test/java/org/apache/karaf/itests/ImportServiceTest.java
----------------------------------------------------------------------
diff --git a/itests/src/test/java/org/apache/karaf/itests/ImportServiceTest.java b/itests/src/test/java/org/apache/karaf/itests/ImportServiceTest.java
index c7cde9f..0287c98 100644
--- a/itests/src/test/java/org/apache/karaf/itests/ImportServiceTest.java
+++ b/itests/src/test/java/org/apache/karaf/itests/ImportServiceTest.java
@@ -29,6 +29,7 @@ import org.ops4j.pax.exam.junit.PaxExam;
 import org.ops4j.pax.exam.spi.reactors.ExamReactorStrategy;
 import org.ops4j.pax.exam.spi.reactors.PerClass;
 import org.osgi.framework.Bundle;
+import org.osgi.framework.Constants;
 
 @RunWith(PaxExam.class)
 @ExamReactorStrategy(PerClass.class)
@@ -37,19 +38,22 @@ public class ImportServiceTest extends KarafTestSupport {
     private static final String BUNDLE2_NAME = "testbundle.require.service";
     private static final String BUNDLE1_NAME = "testbundle.import.service";
 
+    @SuppressWarnings("deprecation")
     @Configuration
     public Option[] config() {
         List<Option> options = new ArrayList<Option>(Arrays.asList(super.config()));
         InputStream testBundleImportService = bundle()
-            .set("Import-Service", "FooService")
-            .set("Bundle-SymbolicName", BUNDLE1_NAME)
-            .set("Bundle-Version", "1.0.0")
+            .set(Constants.IMPORT_SERVICE, "FooService")
+            .set(Constants.BUNDLE_SYMBOLICNAME, BUNDLE1_NAME)
+            .set(Constants.BUNDLE_VERSION, "1.0.0")
+            .set(Constants.BUNDLE_MANIFESTVERSION, "2")
             .build();
         options.add(CoreOptions.streamBundle(testBundleImportService));
         InputStream testBundleRequireService = bundle()
-            .set("Require-Capability", "osgi.service;effective:=active;filter:=\"(objectClass=FooService)\"")
-            .set("Bundle-SymbolicName", BUNDLE2_NAME)
-            .set("Bundle-Version", "1.0.0")
+            .set(Constants.REQUIRE_CAPABILITY, "osgi.service;effective:=active;filter:=\"(objectClass=FooService)\"")
+            .set(Constants.BUNDLE_SYMBOLICNAME, BUNDLE2_NAME)
+            .set(Constants.BUNDLE_VERSION, "1.0.0")
+            .set(Constants.BUNDLE_MANIFESTVERSION, "2")
             .build();
         options.add(CoreOptions.streamBundle(testBundleRequireService));
         return options.toArray(new Option[] {});


Mime
View raw message