Add object mapping test for nested hasMany/hasOne mappings. #1118