### Question:
SimplePageHibernateDao extends GenericDao<SimplePage> implements SimplePageDao { @Override public boolean isExist(String pagePathName) { return getPageByPathName(pagePathName) != null; } SimplePageHibernateDao(SessionFactory sessionFactory); void createPage(SimplePage simplePage); SimplePage getPageByPathName(String pathName); @Override boolean isExist(String pagePathName);  }### Answer:
@Test public void testIsExist() { SimplePage simplePage = ObjectsFactory.getDefaultSimplePage(); session.save(simplePage); assertTrue(dao.isExist(simplePage.getId())); }
@Test public void testIsNotExist() { assertFalse(dao.isExist(-567890L)); }