Added test for bug #46.