public class EntriesPageTest {
@Test
public void testEntriesPage() throws Exception {
EntryService entryServiceMock = EasyMock.createMock(EntryServiceImpl.class);
List<Entry> list = new LinkedList<Entry>();
list.add(new Entry());
Capture<Range> captureRange = new Capture<Range>();
PaginationSupport<Entry> ps = new PaginationSupport<Entry>(list, list.size());
expect(entryServiceMock.search(EasyMock.anyObject(Condition.class), EasyMock.capture(captureRange), EasyMock.anyObject(Sorter.class))).andReturn(ps)
.once();
Entries entries = new Entries(entryServiceMock);
replay(entryServiceMock);