@Test
public void setPageSize() throws Exception {

    PageInfo pageInfo = new PageInfo(PAGE_SIZE, 0, 50, 100);
    assertEquals(10, pageInfo.getPages());
    pageInfo.setPageSize(15);
    assertEquals(7, pageInfo.getPages());
    pageInfo.setPageSize(20);
    assertEquals(5, pageInfo.getPages());
}