@Test
public void testUnselectableDatesNPE() {

    JXMonthView monthView = new JXMonthView();
    try {
        monthView.setUnselectableDates((Date[])null);
        fail("null array must throw NPE");
    } catch (NullPointerException e) {
        // expected
    }
    try {
        monthView.setUnselectableDates(new Date[] {new Date(), null});
        fail("null elements must throw NPE");
    } catch (NullPointerException e) {
        // expected
    }
}