Fix Move and Purge
Add tests