Search in sources :

Example 6 with RuntimeDelegate

use of javax.ws.rs.ext.RuntimeDelegate in project jersey by jersey.

the class RuntimeDelegateImplTest method testCreateEndpoint.

@Test
public void testCreateEndpoint() {
    RuntimeDelegate delegate = RuntimeDelegate.getInstance();
    try {
        delegate.createEndpoint((Application) null, com.sun.net.httpserver.HttpHandler.class);
        fail("IllegalArgumentException should be thrown");
    } catch (IllegalArgumentException iae) {
    // ok - should be thrown
    } catch (Exception e) {
        fail("IllegalArgumentException should be thrown");
    }
}
Also used : RuntimeDelegate(javax.ws.rs.ext.RuntimeDelegate) Test(org.junit.Test)

Aggregations

RuntimeDelegate (javax.ws.rs.ext.RuntimeDelegate)6 HashSet (java.util.HashSet)4 Map (java.util.Map)4 MultivaluedMap (javax.ws.rs.core.MultivaluedMap)4 IOException (java.io.IOException)3 OutputStream (java.io.OutputStream)3 Annotation (java.lang.annotation.Annotation)3 Type (java.lang.reflect.Type)3 URI (java.net.URI)3 ParseException (java.text.ParseException)3 ArrayList (java.util.ArrayList)3 Collections (java.util.Collections)3 Date (java.util.Date)3 HashMap (java.util.HashMap)3 List (java.util.List)3 Locale (java.util.Locale)3 Set (java.util.Set)3 Function (java.util.function.Function)3 Level (java.util.logging.Level)3 Logger (java.util.logging.Logger)3