Added regression test for bug #2.