Add tests for cleanup