Ensure that test query results are returned in a specific for the test's reliability. Refs #17676.