Add test case for cluster query function.