public static boolean isEmpty(Collection<?> collection) {
        return collection == null || collection.isEmpty();
    }
@Test
    void testIsEmpty() {
        assertThat(isEmpty(null), is(true));
        assertThat(isEmpty(new HashSet()), is(true));
        assertThat(isEmpty(emptyList()), is(true));
    }