use of org.jboss.resteasy.specimpl.ResteasyHttpHeaders in project microservice_framework by CJSCommonPlatform.
the class EventPageResourceTest method shouldCheckAccessRights.
@Test
public void shouldCheckAccessRights() throws Exception {
final String streamId = randomUUID().toString();
final ResteasyHttpHeaders requestHeaders = new ResteasyHttpHeaders(new MultivaluedHashMap<>());
resource.headers = requestHeaders;
resource.events(streamId, "3", FORWARD.toString(), 1, new ResteasyUriInfo("", "", ""));
verify(accessControlChecker).checkAccessControl(requestHeaders);
}
use of org.jboss.resteasy.specimpl.ResteasyHttpHeaders in project microservice_framework by CJSCommonPlatform.
the class DefaultRestProcessorTest method headersWithUserId.
private static ResteasyHttpHeaders headersWithUserId(final String userId) {
final ResteasyHttpHeaders headers;
final MultivaluedMapImpl<String, String> requestHeaders = new MultivaluedMapImpl<>();
requestHeaders.add(HeaderConstants.USER_ID, userId);
headers = new ResteasyHttpHeaders(requestHeaders);
return headers;
}
use of org.jboss.resteasy.specimpl.ResteasyHttpHeaders in project microservice_framework by CJSCommonPlatform.
the class EventStreamPageResourceTest method shouldCheckAccessRights.
@Test
public void shouldCheckAccessRights() throws Exception {
final ResteasyHttpHeaders requestHeaders = new ResteasyHttpHeaders(new MultivaluedHashMap<>());
resource.headers = requestHeaders;
resource.events("3", FORWARD.toString(), PAGE_SIZE, new ResteasyUriInfo("", "", ""));
verify(accessControlChecker).checkAccessControl(requestHeaders);
}
Aggregations