@Test public void collectBoolean() { ImmutableCollection<Integer> integers = this.classUnderTest(); ImmutableBooleanCollection immutableCollection = integers.collectBoolean(PrimitiveFunctions.integerIsPositive()); Verify.assertSize(1, immutableCollection); }
@Override @Test public void collectBoolean() { MutableBag<Integer> integers = UnmodifiableBag.of(HashBag.newBagWith(0, 1, 2, 2)); Assert.assertEquals( BooleanHashBag.newBagWith(false, true, true, true), integers.collectBoolean(PrimitiveFunctions.integerIsPositive())); }