improve tests to confirm Query receives correct input