tests for query-result