### Question:
SchedulerUtil { public static long getFrequencyInMillis(DateTime referenceTime, Frequency frequency) { switch (frequency.getTimeUnit()) { case minutes: return MINUTE_IN_MS * frequency.getFrequencyAsInt(); case hours: return HOUR_IN_MS * frequency.getFrequencyAsInt(); case days: return referenceTime.plusDays(frequency.getFrequencyAsInt()).getMillis() - referenceTime.getMillis(); case months: return referenceTime.plusMonths(frequency.getFrequencyAsInt()).getMillis() - referenceTime.getMillis(); default: throw new IllegalArgumentException("Invalid time unit " + frequency.getTimeUnit().name()); } } private  SchedulerUtil(); static long getFrequencyInMillis(DateTime referenceTime, Frequency frequency); static long getPollingFrequencyinMillis(Frequency frequency); static final String MINUTELY_PROCESS_FREQUENCY_POLLING_IN_MILLIS; static final String HOURLY_PROCESS_FREQUENCY_POLLING_IN_MILLIS; static final String DAILY_PROCESS_FREQUENCY_POLLING_IN_MILLIS; static final String MONTHLY_PROCESS_FREQUENCY_POLLING_IN_MILLIS; }### Answer:
@Test(dataProvider = "frequencies") public void testGetFrequencyInMillis(DateTime referenceTime, Frequency frequency, long expectedValue) { Assert.assertEquals(SchedulerUtil.getFrequencyInMillis(referenceTime, frequency), expectedValue); }