Test cases for map function.