new PropertyEventNameMatcher(true, (String[]) null);
fail("Expected exception for PropertyEventNameMatcher constructor");
} catch (IllegalArgumentException ex) {
// expected
}
final PropertyChangeEvent event1 = new PropertyChangeEvent(this, "test", "old", "new");
final PropertyChangeEvent event2 = new PropertyChangeEvent(this, "test", null, null);
final PropertyChangeEvent event3 = new PropertyChangeEvent(this, "hello", "old", "new");
final PropertyChangeEvent event4 = new PropertyChangeEvent(this, "hello", null, null);
final PropertyChangeEvent event5 = new PropertyChangeEvent(this, null, null, null);
Matcher<PropertyChangeEvent> matcher = new PropertyEventNameMatcher(true, new String[] {"test", null});
assertEquals(true, matcher.matches(event1));
assertEquals(true, matcher.matches(event2));
assertEquals(false, matcher.matches(event3));