JobDaoImpl implements JobDao, HasIntCrud<Job> { @Override public Job create(@Nonnull final Job job) { return genericDao.create(job); } @Inject  JobDaoImpl(final JobDbConnProvider jobDbConnProvider); @Override Job create(@Nonnull final Job job); @Override Job update(@Nonnull final Job job); @Override boolean delete(int id); @Override Optional<Job> fetch(int id); @Override ResultPage<Job> find(FindJobCriteria criteria); @Override int deleteOrphans();  }
@Test void descriptionTooLong() { Job job = new Job(); job.setEnabled(true); job.setName(RandomStringUtils.randomAlphabetic(256)); assertThrows(DataAccessException.class, () -> dao.create(job)); }