Implemetn RepositoryQueryTests.
- Adds some query test.