예제 #1
0
 @Test
 public void testDisposeBookDamaged() {
   testingBook.setState(EBookState.DAMAGED);
   try {
     testingBook.dispose();
     fail("Runtime Exception");
   } catch (RuntimeException e) {
     assertTrue(true);
   }
 }
예제 #2
0
 @Test
 public void testDisposeBookLost() {
   testingBook.setState(EBookState.LOST);
   try {
     testingBook.dispose();
     fail("Runtime Exception");
   } catch (RuntimeException e) {
     assertTrue(true);
   }
 }
예제 #3
0
 @Test
 public void testDisposeBookAvailable() {
   testingBook.setState(EBookState.AVAILABLE);
   try {
     testingBook.dispose();
     fail("Runtime Exception");
   } catch (RuntimeException e) {
     assertTrue(true);
   }
 }