SetUtils { public static <T> Set<T> copyOf(Collection<? extends T> values) { return values.isEmpty() ? Collections.emptySet() : Collections.unmodifiableSet(new HashSet<>(values)); } private  SetUtils(); static Set<T> copyOf(Collection<? extends T> values); static Set<T> of(); static Set<T> of(T value); @SafeVarargs @SuppressWarnings("varargs") static Set<T> of(T... values); static Collector<T, ?, Set<T>> toUnmodifiableSet();  }
@Test public void copyOfEmptyIsEmpty() { assertThat(SetUtils.copyOf(Collections.emptyList()), empty()); }
@Test public void copyOfIsSame() { assertThat(SetUtils.copyOf(Collections.singletonList("Jason")), contains("Jason")); }