Added some tests for bug #8088.