test case for subsequence method