Prototype of CDTDatastoreFromQuery

Test case shows how to create a CDTDatastoreFromQuery object and push/pull on it.

Deriving the list of Doc IDs is currently mocked with a fixed list of IDs but this can be replaced with a real implementation once the query work is complete.

Similarly, automatic naming of the database based on the query is not yet present but this is anticipated to be some sort of stable hash based on the query (the same query gets the same name each time).
Good point, actually I can get rid of those now, I was trying to figure out a way of using the delegate to do the purge-after-replicate, and still run a user's delegate. In the end I concluded it was too difficult.