test removing rectangle