I've pushed test cases and the fix for 5.1 to my fork: https://github.com/gbadner/hibernate-core/tree/HHH-10679-5.1