add top and bottom test cases