Esempio n. 1
0
 @Test
 public void notifiesObserversOnIdChange() {
   PropertyChangeListener mockListener = mock(PropertyChangeListener.class);
   connectable.addPropertyChangeListener(mockListener);
   connectable.setId("");
   verify(mockListener).propertyChange(any(PropertyChangeEvent.class));
 }
Esempio n. 2
0
 @Test
 public void defaultNameOffsetValues() {
   assertEquals(-5, connectable.getNameXOffset(), DOUBLE_DELTA);
   assertEquals(35, connectable.getNameYOffset(), DOUBLE_DELTA);
 }