use of easytests.core.options.IssuesOptionsInterface in project easy-tests by malinink.
the class IssuesServiceTest method testFindAllWithOptions.
@Test
public void testFindAllWithOptions() throws Exception {
final List<IssueEntity> issuesEntities = this.getIssuesEntities();
final List<IssueModelInterface> issuesModels = this.getIssuesModels();
final IssuesOptionsInterface issuesOptions = Mockito.mock(IssuesOptionsInterface.class);
given(this.issuesMapper.findAll()).willReturn(issuesEntities);
given(issuesOptions.withRelations(Mockito.anyList())).willReturn(issuesModels);
final List<IssueModelInterface> foundedIssuesModels = this.issuesService.findAll(issuesOptions);
verify(issuesOptions).withRelations(issuesModels);
Assert.assertEquals(issuesModels, foundedIssuesModels);
}
Aggregations