test for remove and clear