add test code for Stack