handleQuery test added