### Question:
ToolVulnerabilityDao extends NamedParameterJdbcDaoSupport { @Transactional(propagation = Propagation.MANDATORY) public void deleteVulnerabilities(long toolId, String version) { MapSqlParameterSource params = new MapSqlParameterSource(); params.addValue(ToolVulnerabilityColumns.TOOL_ID.name(), toolId); params.addValue(ToolVulnerabilityColumns.VERSION.name(), version); getNamedParameterJdbcTemplate().update(deleteVulnerabilitiesQuery, params); }  @Transactional(propagation = Propagation.MANDATORY) void createVulnerabilityRecords(List<Vulnerability> vulnerabilities, long toolId, String version); List<Vulnerability> loadVulnerabilities(long toolId, String version); Map<String, List<Vulnerability>> loadVulnerabilities(long toolId); @Transactional(propagation = Propagation.MANDATORY) void deleteVulnerabilities(long toolId, String version); @Transactional(propagation = Propagation.MANDATORY) void createDependencyRecords(List<ToolDependency> dependencies, long toolId, String version); List<ToolDependency> loadDependencies(long toolId, String version); Map<String, List<ToolDependency>> loadDependencies(long toolId); @Transactional(propagation = Propagation.MANDATORY) void deleteDependencies(long toolId, String version); @Transactional(propagation = Propagation.MANDATORY) void insertToolVersionScan(long toolId, String version, ToolOSVersion toolOSVersion, String layerRef,
                                      String digest, ToolScanStatus newStatus, Date scanDate); @Transactional(propagation = Propagation.MANDATORY) void updateToolVersionScan(long toolId, String version, ToolOSVersion toolOSVersion, String layerRef,
                                      String digest, ToolScanStatus newStatus, Date scanDate, boolean whiteList); @Transactional(propagation = Propagation.MANDATORY) void deleteToolVersionScan(long toolId, String version); @Transactional(propagation = Propagation.MANDATORY) void updateWhiteListWithToolVersion(long toolId, String version,
                                                                boolean fromWhiteList); Optional<ToolVersionScanResult> loadToolVersionScan(long toolId, String version); Map<String, ToolVersionScanResult> loadAllToolVersionScans(long toolId); @Required void setInsertVulnerabilitiesQuery(String insertVulnerabilitiesQuery); @Required void setLoadToolVersionScanQuery(String loadToolVersionScanQuery); @Required void setLoadVulnerabilitiesByToolAndVersionQuery(String loadVulnerabilitiesByToolAndVersionQuery); @Required void setDeleteVulnerabilitiesQuery(String deleteVulnerabilitiesQuery); @Required void setLoadVulnerabilitiesByToolQuery(String loadVulnerabilitiesByToolQuery); @Required void setInsertToolVersionScanQuery(String insertToolVersionScanQuery); @Required void setDeleteToolVersionScansQuery(String deleteToolVersionScansQuery); @Required void setUpdateToolVersionScanQuery(String updateToolVersionScanQuery); @Required void setUpdateToolVersionScanWithSuccessQuery(String updateToolVersionScanWithSuccessQuery); @Required void setLoadToolAllVersionScansQuery(String loadToolAllVersionScansQuery); @Required void setInsertToolDependencyQuery(String insertToolDependencyQuery); @Required void setLoadDependencyByToolAndVersionQuery(String loadDependencyByToolAndVersionQuery); @Required void setLoadDependencyByToolQuery(String loadDependencyByToolQuery); @Required void setDeleteDependencyQuery(String deleteDependencyQuery); @Required void setUpdateWhiteListWithToolVersionQuery(String updateWhiteListWithToolVersionQuery);  }### Answer:
@Test @Transactional(propagation = Propagation.REQUIRES_NEW) public void testDeleteVulnerabilities() { createVulnerability(tool, LATEST_VERSION); Assert.assertFalse(toolVulnerabilityDao.loadVulnerabilities(tool.getId(), LATEST_VERSION).isEmpty()); toolVulnerabilityDao.deleteVulnerabilities(tool.getId(), LATEST_VERSION); Assert.assertTrue(toolVulnerabilityDao.loadVulnerabilities(tool.getId(), LATEST_VERSION).isEmpty()); }