### Question:
DefaultSystemStatusAccessor implements SystemStatusAccessor { @Override @Transactional public OffsetDateTime getStartupTime() { return getSystemStatus().getStartupTime(); } @Autowired  DefaultSystemStatusAccessor(SystemStatusRepository systemStatusRepository); @Override @Transactional boolean isSystemInitialized(); @Override @Transactional void setSystemInitialized(boolean systemInitialized); @Override @Transactional void startupOccurred(); @Override @Transactional OffsetDateTime getStartupTime(); static final Long SYSTEM_STATUS_ID; }### Answer:
@Test public void getStartupTime() { SystemStatusRepository systemStatusRepository = Mockito.mock(SystemStatusRepository.class); OffsetDateTime date = DateUtils.createCurrentDateTimestamp(); SystemStatusEntity systemStatus = new SystemStatusEntity(Boolean.TRUE, date); Mockito.when(systemStatusRepository.findById(Mockito.any())).thenReturn(Optional.of(systemStatus)); DefaultSystemStatusAccessor systemStatusUtility = new DefaultSystemStatusAccessor(systemStatusRepository); assertEquals(date, systemStatusUtility.getStartupTime()); }