Added regression test for the issue fixed by 4c0e5da.