add testcase for ticket 3157