tests for cleanup.removeFields and cleanup.extractAllFields