### Question:
RunScheduleDao extends NamedParameterJdbcDaoSupport { @Transactional(propagation = Propagation.REQUIRED) public void updateRunSchedules(final List<RunSchedule> schedules) { final MapSqlParameterSource[] params = schedules.stream() .map(RunScheduleParameters::getParameters) .collect(Collectors.toList()) .toArray(new MapSqlParameterSource[schedules.size()]); getNamedParameterJdbcTemplate().batchUpdate(updateRunScheduleQuery, params); }  @Transactional(propagation = Propagation.MANDATORY) Long createScheduleId(); @Transactional(propagation = Propagation.MANDATORY) void createRunSchedules(final List<RunSchedule> schedules); @Transactional(propagation = Propagation.REQUIRED) void updateRunSchedules(final List<RunSchedule> schedules); List<RunSchedule> loadAllRunSchedulesBySchedulableIdAndType(final Long schedulableId,
                                                                       final ScheduleType scheduleType); List<RunSchedule> loadAllRunSchedules(); Optional<RunSchedule> loadRunSchedule(final Long id); @Transactional(propagation = Propagation.MANDATORY) void deleteRunSchedules(final List<Long> ids); @Transactional(propagation = Propagation.MANDATORY) void deleteRunSchedules(final Long runId, final ScheduleType scheduleType); void deleteRunSchedulesForRunByPipeline(final Long pipelineId); @Required void setScheduleSequence(final String scheduleSequence); @Required void setCreateRunScheduleQuery(final String createRunScheduleQuery); @Required void setUpdateRunScheduleQuery(final String updateRunScheduleQuery); @Required void setDeleteRunScheduleQuery(final String deleteRunScheduleQuery); @Required void setLoadRunScheduleQuery(final String loadRunScheduleQuery); @Required void setLoadAllRunSchedulesByRunIdQuery(final String loadAllRunSchedulesByRunIdQuery); @Required void setLoadAllRunSchedulesQuery(final String loadAllRunSchedulesQuery); @Required void setDeleteRunSchedulesForRunQuery(final String deleteRunSchedulesForRunQuery); @Required void setDeleteRunSchedulesForRunByPipelineIdQuery(final String deleteRunSchedulesForRunByPipelineIdQuery);  }### Answer:
@Test public void testUpdateRunSchedules() { runScheduleDao.createRunSchedules(Arrays.asList(testRunSchedule, testRunSchedule2)); runScheduleDao.createRunSchedules(Collections.singletonList(testConfRunSchedule)); testUpdatedRunSchedule.setId(testRunSchedule.getId()); testUpdatedRunSchedule2.setId(testRunSchedule2.getId()); runScheduleDao.updateRunSchedules(Arrays.asList(testUpdatedRunSchedule, testUpdatedRunSchedule2)); loadAndAssertSchedule(testUpdatedRunSchedule); loadAndAssertSchedule(testUpdatedRunSchedule2); testConfRunSchedule.setCronExpression(CRON_EXPRESSION2); runScheduleDao.updateRunSchedules(Collections.singletonList(testConfRunSchedule)); loadAndAssertSchedule(testConfRunSchedule); }