Exemplo n.º 1
0
  @Test
  public void remove() {
    RemoveAction sut = new RemoveAction(transaction, eventNotification);
    sut.remove(event);

    verify(transaction).remove(event);
    verify(transaction).commit();
    verify(eventNotification).cancel(event.getID());
  }
Exemplo n.º 2
0
 @Before
 public void setUp() {
   when(event.getID()).thenReturn(3);
   when(transaction.remove(any(IEvent.class))).thenReturn(transaction);
 }