test iterator for map