@Test
public void listEnvironments() {

     List<Environment> environments = new ArrayList<>();
     environments.add(environment);
     Mockito.when(this.environmentRepository.findAll(Mockito.any(Example.class)))
            .thenReturn(environments);
     List<Environment> environmentResp = this.environmentService.list(this.environmentDTO);
     assertEquals(environments.size(), environmentResp.size());
     Mockito.verify(this.environmentRepository, Mockito.times(1)).findAll(Mockito.any(Example.class));
}