Added regression test for issue 23