Adding test for #811
Adding fix for #811 from #813