### Question:
HubBlacklistDAOFileImpl implements HubBlacklistDAO, ResourceListener { @Override public BlacklistedHub save(BlacklistedHub hub) { if (hub != null) { Date blacklistedDate = hub.getBlacklistedDate() != null ? hub.getBlacklistedDate() : new Date(); BlacklistedHub newHub = hub.copy(); newHub.setBlacklistedDate(blacklistedDate); getCachedData().put(hub.getCertSn(), newHub); return newHub; } return null; } HubBlacklistDAOFileImpl(); @PostConstruct void init(); @Override BlacklistedHub findBlacklistedHubByCertSn(String certSn); @Override BlacklistedHub save(BlacklistedHub hub); @Override void delete(BlacklistedHub hub); @Override void onChange();  }### Answer:
@Test public void testSave() { String cert = "testSaveCert1"; BlacklistedHub newHub = createNew(cert); assertNotNull(newHub); BlacklistedHub fromDb = hubBlacklistDAO.findBlacklistedHubByCertSn(cert); assertEquals(newHub, fromDb); }