Search in sources :

Example 1 with UriInfo

use of jakarta.ws.rs.core.UriInfo in project OpenGrok by OpenGrok.

the class IncomingFilterTest method mockContainerRequestContext.

private ContainerRequestContext mockContainerRequestContext(final String path) {
    ContainerRequestContext context = mock(ContainerRequestContext.class);
    UriInfo info = mock(UriInfo.class);
    when(info.getPath()).thenReturn(path);
    when(context.getUriInfo()).thenReturn(info);
    return context;
}
Also used : ContainerRequestContext(jakarta.ws.rs.container.ContainerRequestContext) UriInfo(jakarta.ws.rs.core.UriInfo)

Aggregations

ContainerRequestContext (jakarta.ws.rs.container.ContainerRequestContext)1 UriInfo (jakarta.ws.rs.core.UriInfo)1