IsNotInMatcher extends AbstractCollectionMatcher { @Override protected boolean matches(Object actual, Collection collection) { return !collection.contains(actual); }    }
@Test public void testWhenItemIsNull() { assertThat(new IsNotInMatcher().matches(null, Collections.emptyList()), is(true)); }
@Test public void testWhenItemIsInCollection() { assertThat(new IsNotInMatcher().matches(1, Arrays.asList(1, 2, 3, 4)), is(false)); }
@Test public void testWhenItemIsNotInCollection() { assertThat(new IsNotInMatcher().matches(1, Arrays.asList(3, 4, 5, 6)), is(true)); }