Improve map functions for map*Key* tests