Is there some way to get some more detail from automapper when I get this exception:
AutoMapper.AutoMapperMappingException
Often it will tell me the 2 types of the mapping, but not which resolver or part of the mapping is failing.
Is there some way to get some more detail from automapper when I get this exception:
AutoMapper.AutoMapperMappingException
Often it will tell me the 2 types of the mapping, but not which resolver or part of the mapping is failing.
Simple answer, is to call this method, preferably in your unit test.
see: http://docs.automapper.org/en/stable/Getting-started.html#how-do-i-test-my-mappings
One thing that fixed my problem was adding this line to the mapping.
Not sure why this isn't the default behavior.