@Test public void setTimeoutTest() { final TimeAmount tenMinutes = TimeAmount.TEN_MINUTES; doReturn(1234L).when(genericErrorTimeController).now(); genericErrorTimeController.setTimeout(tenMinutes); assertEquals(1234L + tenMinutes.getTimeAmount(), genericErrorTimeController.getExpiresOn()); }
public void setTimeout(final TimeAmount duration) { expiresOn = now() + duration.getTimeAmount(); }
GenericErrorTimeController { public void setTimeout(final TimeAmount duration) { expiresOn = now() + duration.getTimeAmount(); } }
GenericErrorTimeController { public void setTimeout(final TimeAmount duration) { expiresOn = now() + duration.getTimeAmount(); }  }
GenericErrorTimeController { public void setTimeout(final TimeAmount duration) { expiresOn = now() + duration.getTimeAmount(); }  boolean isExpired(); void setTimeout(final TimeAmount duration); }
GenericErrorTimeController { public void setTimeout(final TimeAmount duration) { expiresOn = now() + duration.getTimeAmount(); }  boolean isExpired(); void setTimeout(final TimeAmount duration);  }