add a test for bug 2974