### Question:
SupplyChainValidationSummary extends ArchivableEntity { public Set<SupplyChainValidation> getValidations() { return Collections.unmodifiableSet(validations); } protected  SupplyChainValidationSummary();  SupplyChainValidationSummary(final Device device,
            final Collection<SupplyChainValidation> validations); static SupplyChainValidationSummary.Selector select(
            final CrudManager<SupplyChainValidationSummary> certMan); Device getDevice(); AppraisalStatus.Status getOverallValidationResult(); String getMessage(); Set<SupplyChainValidation> getValidations();  }### Answer:
@Test public void testSaveAndGetEmpty() { DBManager<SupplyChainValidationSummary> supplyMan = new DBManager<>( SupplyChainValidationSummary.class, sessionFactory ); SupplyChainValidationSummary emptySummary = getTestSummary( 0, 0, Collections.emptyList() ); SupplyChainValidationSummary savedEmptySummary = supplyMan.save(emptySummary); SupplyChainValidationSummary retrievedEmptySummary = supplyMan.get(savedEmptySummary.getId()); Assert.assertEquals(retrievedEmptySummary, emptySummary); Assert.assertEquals(retrievedEmptySummary.getValidations().size(), 0); }
@Test public void testSaveAndGetSmall() { DBManager<SupplyChainValidationSummary> supplyMan = new DBManager<>( SupplyChainValidationSummary.class, sessionFactory ); List<ArchivableEntity> singleCert = certificates.subList(0, 1); SupplyChainValidationSummary smallSummary = getTestSummary( 1, 0, singleCert ); SupplyChainValidationSummary savedSmallSummary = supplyMan.save(smallSummary); SupplyChainValidationSummary retrievedSmallSummary = supplyMan.get(savedSmallSummary.getId()); Assert.assertEquals(retrievedSmallSummary, smallSummary); Assert.assertEquals( new ArrayList<>(retrievedSmallSummary.getValidations()) .get(0).getCertificatesUsed(), singleCert ); }