ResultMapping: do not shortcut the configuration.

Since it's only used to get the ClassMetadataFactoryName object, it's
not really necessary to add an extra method to get the configuration out
of the EntityManager.
ResultMapping: refactor tests.