### Question:
AbstractDAO implements DAO<TInterface> { @Override public boolean exists(UID uid) { Class<? extends TEntity> entityClass = this.getEntityClass(); TEntity entity = Ebean.find(entityClass).where().eq("uid", uid.toString()).findOne(); return entity != null; }  @Override void beginTransaction(); @Override void rollback(); @Override void setForRollback(); @Override boolean isSetForRollback(); @Override void commit(); @Override void lock(TInterface entity, LockModeType type); @Override boolean isTransactionActive(); @Override @SuppressWarnings("unchecked") TInterface get(UID uid); @Override @SuppressWarnings("unchecked") TInterface create(final TInterface entity); @Override @SuppressWarnings("unchecked") final synchronized TInterface update(final TInterface entity); @Override boolean exists(UID uid);  }### Answer:
@Test public void exists() { boolean exists = AbstractDAOTest.abstractDAO.exists(AbstractDAOTest.existingObjUid); Assert.assertEquals(exists, true); }
@Test public void exists_noSuchUid() { boolean exists = AbstractDAOTest.abstractDAO.exists(AbstractDAOTest.nonExistingObjUid); Assert.assertEquals(exists, false); }
@Test public void exists_inactive() { boolean exists = AbstractDAOTest.abstractDAO.exists(AbstractDAOTest.inactiveObjUid); Assert.assertEquals(exists, false); }