Added formatting to mapreduce test function