Test code for search