HHH-6457 Improve how BaseCoreFunctionalTestCase builds SessionFactory from new metadata mappings