### Question:
HistoryProvider implements IHistoryProvider { @Override public ArrayList<IRainbowMessage> getEventRangeByType(String channel, Date startTime, Date endTime) { ArrayList<IRainbowMessage> model; model = (ArrayList<IRainbowMessage>) databaseconn.getEventRangeByType( channel, startTime, endTime); return model; } HistoryProvider(IDatabaseConnector databaseCon);  HistoryProvider(ISystemViewProvider acmeSystemViewProvider,
            ISystemConfiguration systemConfig); @Override IModelInstance<?> getModelState(Date time); @Override ArrayList<IRainbowMessage> getEventRange(Date startTime, Date endTime); @Override ArrayList<IRainbowMessage> getEventRangeByType(String channel,
            Date startTime, Date endTime); @Override ArrayList<IRainbowMessage> getModelEventRange(Date startTime,
            Date endTime); @Override IRainbowMessage getEvent(Date time); @Override void setSession(String name); @Override ArrayList<String> getSessionList(); String getReadSession(); @Override Date getStartDate(); @Override boolean currentSessionIsWriteSession(); @Override Date getMaxDate(); @Override List<IRainbowMessage> getNumberOfEventsBefore(Date endTime,
            int numEvents); @Override void closeDatabaseConnection();  }### Answer:
@Test public void testgetEventRangeByType() { List<IRainbowMessage> events = null; Calendar cal1 = Calendar.getInstance(); Date date1 = cal1.getTime(); Calendar cal2 = Calendar.getInstance(); Date date2 = cal2.getTime(); events = hp.getEventRangeByType("channel", date1, date2); assertNotNull(events); }