@Override
    public boolean remove(Object o) {
        checkNotNull(o, "Item to be removed cannot be null.");
        return items.remove(serializer.encode(o));
    }
@Test
    public void testRemove() throws Exception {
        //Test removal
        fillSet(10, set);
        for (int i = 0; i < 10; i++) {
            assertEquals("The size of the set is wrong.", 10 - i, set.size());
            assertTrue("The first removal should be true.", set.remove(i));
            assertFalse("The second removal should be false (item no longer contained).", set.remove(i));
        }
        assertTrue("All elements should have been removed.", set.isEmpty());
    }