@Test
public void shouldFindAllJobTypes() throws Exception {

    // Given
    final OffsetDateTime now = OffsetDateTime.now();
    final JobInfo eins = someRunningJobInfo("jobEins", "someJobTypeEins", now);
    final JobInfo zwei = someRunningJobInfo("jobZwei", "someJobTypeZwei", now.plusSeconds(1));
    final JobInfo drei = someRunningJobInfo("jobDrei", "someJobTypeDrei", now.plusSeconds(2));
    final JobInfo vierWithTypeDrei = someRunningJobInfo("jobVier", "someJobTypeDrei", now.plusSeconds(3));
    repo.createOrUpdate(eins);
    repo.createOrUpdate(zwei);
    repo.createOrUpdate(drei);
    repo.createOrUpdate(vierWithTypeDrei);
    // When
    final List<String> allJobIds = repo.findAllJobIdsDistinct();
    // Then
    assertThat(allJobIds, hasSize(3));
    assertThat(allJobIds, containsInAnyOrder("jobEins", "jobZwei", "jobVier"));
}