use of io.elastest.etm.model.SutExecution in project elastest-torm by elastest.
the class SutServiceTest method setUp.
@BeforeEach
public void setUp() {
sut = new SutSpecification();
sutExec = new SutExecution(1L, sut, null, null);
}
use of io.elastest.etm.model.SutExecution in project elastest-torm by elastest.
the class SutServiceTest method testCreateSutExecutionBySut.
@Test
public void testCreateSutExecutionBySut() {
when(sutExecutionRepository.save(Mockito.any(SutExecution.class))).thenReturn(sutExec);
SutExecution sutExec = sutService.createSutExecutionBySut(sut);
assertTrue(sutExec.getSutSpecification().getId() == this.sut.getId());
}
use of io.elastest.etm.model.SutExecution in project elastest-torm by elastest.
the class SutServiceTest method testModifySutExec.
@Test
public void testModifySutExec() {
when(sutExecutionRepository.findOne(Mockito.anyLong())).thenReturn(sutExec);
when(sutExecutionRepository.save(Mockito.any(SutExecution.class))).thenReturn(sutExec);
SutExecution sutExecResult = sutService.modifySutExec(sutExec);
assertTrue(sutExecResult.getId() == sutExec.getId());
}
Aggregations