Advertisement
k-joseph

Untitled

Aug 27th, 2013
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.89 KB | None | 0 0
  1. /**
  2. * @see {@link EncounterService#saveEncounterType(EncounterType)}}
  3. * @see {@link EncounterService#checkIfEncounterTypesAreLocked()}}
  4. */
  5. @Test(expected = EncounterTypeLockedException.class)
  6. @Verifies(value = "throw error when trying to save encounter type when encounter types are locked", method = "saveEncounterType(EncounterType)")
  7. public void saveEncounterType_throwErrorWhenTryingToSaveEncounterTypeWhenEncounterTypesAreLocked() throws Exception {
  8. // dataset to lock encounter types
  9. executeDataSet("../../../../../../../web/src/test/resources/org/openmrs/web/encounter/include/EncounterTypeFormControllerTest.xml");
  10.  
  11. EncounterService encounterService = Context.getEncounterService();
  12. EncounterType encounterType = Context.getEncounterService().getEncounterType(1);
  13.  
  14. Assert.assertNotNull(encounterType);
  15.  
  16. encounterService.saveEncounterType(encounterType);
  17. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement