コード例 #1
0
 /**
  * @see getLabPrecondition(Integer labPreconditionId)
  * @verifies get LabPrecondition by LabPreconditionId
  */
 @Test
 @SkipBaseSetup
 public void getLabPrecondition_shouldGetLabPrecondition() throws Exception {
   LabPrecondition labPrecondition =
       Context.getService(LabCatalogService.class).getLabPrecondition(33333067);
   Assert.assertNotNull("getLabPreconditionByUuid should not return null", labPrecondition);
   Assert.assertEquals(
       "getLabPreconditionByUuid should return the right object",
       "0100dc0a-46da-11e1-99f4-0024e8c61285",
       labPrecondition.getUuid());
 }
コード例 #2
0
 /**
  * @see LabCatalogService#saveLabPrecondition(LabPrecondition labLabPrecondition)
  * @verifies save LabPrecondition
  */
 @Test
 @SkipBaseSetup
 public void saveLabPrecondition_shouldSaveRecord() throws Exception {
   LabPrecondition labPrecondition =
       Context.getService(LabCatalogService.class)
           .getLabPreconditionByUuid("0100dc0a-46da-11e1-99f4-0024e8c61285");
   labPrecondition.setUuid("12312312-1231-1231-1231-123123123");
   Context.getService(LabCatalogService.class).saveLabPrecondition(labPrecondition);
   labPrecondition =
       Context.getService(LabCatalogService.class)
           .getLabPreconditionByUuid("12312312-1231-1231-1231-123123123");
   Assert.assertNotNull("saveLabPrecondition should not return null", labPrecondition);
   Assert.assertEquals(
       "saveLabPrecondition should return the right object",
       "12312312-1231-1231-1231-123123123",
       labPrecondition.getUuid());
 }