bag.applyLimit(15);
assertEquals(12, bag.size());
bag.remove(wrap(null, bag.getCollectionType().getElementType()));
assertEquals(11, bag.size());
assertEquals(1, bag.occurrences(wrap(null, bag.getCollectionType().getElementType())));
bag.remove(wrap("three", bag.getCollectionType().getElementType()));
assertEquals(10, bag.size());
assertEquals(2, bag.occurrences(wrap("three", bag.getCollectionType().getElementType())));
if (temp.contains(wrap(intg, bag.getCollectionType().getElementType()))) {
int occurrence = bag.occurrences(wrap(intg, bag.getCollectionType().getElementType()));
assertTrue(bag.remove(wrap(intg, bag.getCollectionType().getElementType())));
assertEquals(--occurrence,
bag.occurrences(wrap(intg, bag.getCollectionType().getElementType())));
assertTrue(bag.remove(wrap(null, bag.getCollectionType().getElementType())));
assertEquals(--occurrence,
bag.occurrences(wrap(null, bag.getCollectionType().getElementType())));
bag.remove(wrap(null, bag.getCollectionType().getElementType()));
assertEquals(wrap(null, bag.getCollectionType().getElementType()), itr.next());
assertFalse(itr.hasNext());
bag.remove(wrap(null, bag.getCollectionType().getElementType()));
assertEquals(0, bag.size());
assertFalse(bag.contains(wrap(null, bag.getCollectionType().getElementType())));