aries-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From csie...@apache.org
Subject [05/14] aries-jax-rs-whiteboard git commit: Not according to spec
Date Fri, 18 Aug 2017 14:01:54 GMT
Not according to spec


Project: http://git-wip-us.apache.org/repos/asf/aries-jax-rs-whiteboard/repo
Commit: http://git-wip-us.apache.org/repos/asf/aries-jax-rs-whiteboard/commit/7450672c
Tree: http://git-wip-us.apache.org/repos/asf/aries-jax-rs-whiteboard/tree/7450672c
Diff: http://git-wip-us.apache.org/repos/asf/aries-jax-rs-whiteboard/diff/7450672c

Branch: refs/heads/master
Commit: 7450672cdb8ce4db7634573a1ad6c059f85fc5e3
Parents: 2984180
Author: Carlos Sierra <csierra@apache.org>
Authored: Mon Aug 14 14:17:02 2017 +0200
Committer: Carlos Sierra <csierra@apache.org>
Committed: Fri Aug 18 15:59:21 2017 +0200

----------------------------------------------------------------------
 jax-rs.itests/src/main/java/test/JaxrsTest.java | 30 --------------------
 1 file changed, 30 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/aries-jax-rs-whiteboard/blob/7450672c/jax-rs.itests/src/main/java/test/JaxrsTest.java
----------------------------------------------------------------------
diff --git a/jax-rs.itests/src/main/java/test/JaxrsTest.java b/jax-rs.itests/src/main/java/test/JaxrsTest.java
index b8abfa3..951a2cb 100644
--- a/jax-rs.itests/src/main/java/test/JaxrsTest.java
+++ b/jax-rs.itests/src/main/java/test/JaxrsTest.java
@@ -17,7 +17,6 @@
 
 package test;
 
-import static org.junit.Assert.assertNotNull;
 import static org.osgi.service.jaxrs.whiteboard.JaxRSWhiteboardConstants.*;
 
 import java.util.Dictionary;
@@ -29,8 +28,6 @@ import org.osgi.framework.PrototypeServiceFactory;
 import org.osgi.framework.ServiceFactory;
 import org.osgi.framework.ServiceRegistration;
 
-import org.osgi.service.jaxrs.runtime.dto.FailedApplicationDTO;
-import org.osgi.util.tracker.ServiceTracker;
 import test.types.TestAddon;
 import test.types.TestAddonConflict;
 import test.types.TestAddonConflict2;
@@ -85,12 +82,6 @@ public class JaxrsTest extends TestHelper {
             target("http://localhost:8080").
             path("test-application");
 
-        @SuppressWarnings("rawtypes")
-        ServiceTracker serviceTracker = new ServiceTracker<>(
-            bundleContext, FailedApplicationDTO.class, null);
-
-        serviceTracker.open();
-
         ServiceRegistration<?> serviceRegistration = null;
         ServiceRegistration<?> serviceRegistration2;
 
@@ -103,8 +94,6 @@ public class JaxrsTest extends TestHelper {
                 "Hello application",
                 response.readEntity(String.class));
 
-            assertNull(serviceTracker.getService());
-
             serviceRegistration2 = registerApplication(
                 new TestApplicationConflict(), "service.ranking", -1);
 
@@ -113,16 +102,12 @@ public class JaxrsTest extends TestHelper {
             assertEquals(
                 "Hello application", response.readEntity(String.class));
 
-            assertNotNull(serviceTracker.getService());
-
             assertEquals(
                 Response.Status.NOT_FOUND.getStatusCode(),
                 webTarget.path("conflict").request().get().getStatus());
 
             serviceRegistration2.unregister();
 
-            assertNull(serviceTracker.getService());
-
             response = webTarget.request().get();
 
             assertEquals(
@@ -132,8 +117,6 @@ public class JaxrsTest extends TestHelper {
             if (serviceRegistration != null) {
                 serviceRegistration.unregister();
             }
-
-            serviceTracker.close();
         }
     }
 
@@ -145,11 +128,6 @@ public class JaxrsTest extends TestHelper {
             target("http://localhost:8080").
             path("test-application");
 
-        @SuppressWarnings("rawtypes")
-        ServiceTracker serviceTracker = new ServiceTracker<>(
-            bundleContext, FailedApplicationDTO.class, null);
-
-        serviceTracker.open();
 
         ServiceRegistration<?> serviceRegistration = null;
         ServiceRegistration<?> serviceRegistration2;
@@ -163,8 +141,6 @@ public class JaxrsTest extends TestHelper {
                 "Hello application",
                 response.readEntity(String.class));
 
-            assertNull(serviceTracker.getService());
-
             serviceRegistration2 = registerApplication(
                 new TestApplicationConflict(), "service.ranking", 1);
 
@@ -174,16 +150,12 @@ public class JaxrsTest extends TestHelper {
                 "Hello application conflict",
                 response.readEntity(String.class));
 
-            assertNotNull(serviceTracker.getService());
-
             assertEquals(
                 "conflict",
                 webTarget.path("conflict").request().get(String.class));
 
             serviceRegistration2.unregister();
 
-            assertNull(serviceTracker.getService());
-
             response = webTarget.request().get();
 
             assertEquals(
@@ -193,8 +165,6 @@ public class JaxrsTest extends TestHelper {
             if (serviceRegistration != null) {
                 serviceRegistration.unregister();
             }
-
-            serviceTracker.close();
         }
     }
 


Mime
View raw message