more comprehensive tests for querying