fix flatmap test