@Test
public void getUserRolesTest() {

    Response response = target().path("users/" + UsernameTestFilter.USERNAME + "/roles").request().get();
    verify(engineManager).retrieveUser(UsernameTestFilter.USERNAME);
    assertEquals(response.getStatus(), 200);
    try {
        JSONArray result = JSONArray.fromObject(response.readEntity(String.class));
        assertEquals(result.size(), roles.size());
    } catch (Exception e) {
        fail("Expected no exception, but got: " + e.getMessage());
    }
}