@Test
public void testSpuriousEnabledListening() {

    JXDatePicker picker = new JXDatePicker();
    Component button = null;
    for (int i = 0; i < picker.getComponentCount(); i++) {
        if (picker.getComponent(i) instanceof JButton) {
            button = picker.getComponent(i);
        }
    }
    if (button == null) {
        LOG.info("cannot run testEnabledListening - no button found");
        return;
    }
    button.setEnabled(false);
    // sanity - that at least the other views are uneffected
    assertTrue(picker.isEnabled());
    assertTrue(picker.getEditor().isEnabled());
    assertFalse("Do not change the state of the sender during notification processing", 
            button.isEnabled());
}