added test to ensure that mapping to object functor will pass key as the second argument