fixing valid query test