Tests: use new instance per test case.

This way the next test is not influenced by the previous.
Tests: add query data management tests.
Tests: move test host definition to bootstrap.

For easier access.
Queries: add public getters for usable info.
Tests: test building of query.
Tests: test building of a query with dynamic data.
Tests: test getting and creating an index.
Tests: test deleting of an index.
Resolve merge conflicts.