added last test
This commit is contained in:
parent
ee092b86e1
commit
aed4d6605d
BIN
data.mv.db
BIN
data.mv.db
Binary file not shown.
@ -45,6 +45,7 @@ class SbappApplicationTests {
|
|||||||
Assertions.assertThrows(EntityNotFoundException.class, () -> orderService.findOrder(order0.getId()));
|
Assertions.assertThrows(EntityNotFoundException.class, () -> orderService.findOrder(order0.getId()));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
void testFavor(){
|
void testFavor(){
|
||||||
componentService.deleteAllComponent();
|
componentService.deleteAllComponent();
|
||||||
@ -66,4 +67,18 @@ class SbappApplicationTests {
|
|||||||
Assertions.assertThrows(EntityNotFoundException.class, () -> favorService.findFavor(favor0.getId()));
|
Assertions.assertThrows(EntityNotFoundException.class, () -> favorService.findFavor(favor0.getId()));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@Test
|
||||||
|
void testComponent(){
|
||||||
|
componentService.deleteAllComponent();
|
||||||
|
orderService.deleteAllOrder();
|
||||||
|
favorService.deleteAllFavor();
|
||||||
|
|
||||||
|
final Component component0 = componentService.addComponent("comp", 111);
|
||||||
|
final Component component1 = componentService.findComponent(component0.getId());
|
||||||
|
Assertions.assertEquals(component0, component1);
|
||||||
|
|
||||||
|
componentService.deleteComponent(component0.getId());
|
||||||
|
Assertions.assertThrows(EntityNotFoundException.class, () -> componentService.findComponent(component0.getId()));
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user