use of com.cribbstechnologies.clients.mandrill.model.response.users.UsersSendersResponse in project Java-Mandrill-Wrapper by cribbstechnologies.
the class MandrillUsersRequestTest method testGetSenders.
@Test
public void testGetSenders() throws RequestFailedException {
usersRequest.setRequest(request);
UsersSendersResponse response = new UsersSendersResponse();
Mockito.when(request.postRequest(bmr, ServiceMethods.Users.SENDERS, UsersSendersResponse.class, usersRequest.getUsersListReference())).thenReturn(response);
usersRequest.getSenders(bmr);
Mockito.verify(request).postRequest(bmr, ServiceMethods.Users.SENDERS, UsersSendersResponse.class, usersRequest.getUsersListReference());
}
use of com.cribbstechnologies.clients.mandrill.model.response.users.UsersSendersResponse in project Java-Mandrill-Wrapper by cribbstechnologies.
the class MandrillUsersRequest method getSenders.
/**
* Return the senders that have tried to use this account, both verified and unverified
*
* @param sendersRequest
* a populated @see com.cribbstechnologies.clients.mandrill.model.BaseMandrillRequest
* @throws RequestFailedException
*/
public UsersSendersResponse getSenders(BaseMandrillRequest sendersRequest) throws RequestFailedException {
UsersSendersResponse response = new UsersSendersResponse();
response.setList(((BaseMandrillAnonymousListResponse<MandrillSender>) request.postRequest(sendersRequest, ServiceMethods.Users.SENDERS, UsersSendersResponse.class, usersListReference)).getList());
return response;
}
Aggregations