add tests to get readable table names with subquery