Added query validation functions, fleshed out tests
Merge pull request #46 from wri/feature/fix-35

Added query validation functions, fleshed out tests