@Test
public void testCompareTo() {

    // given
    BooleanHolder[] array = {
        new BooleanHolder(true),
        new BooleanHolder(null),
        new BooleanHolder(false)
    };
    // when
    Arrays.sort(array);
    // then - expected sorted array
    assertEquals(null, array[0].getValue());
    assertEquals(false, (boolean) array[1].getValue());
    assertEquals(true, (boolean) array[2].getValue());
}