Port tests for CDTIndexManager to new CRUD API
Fix bug where new create CRUD API didn't fire change notifications
correctly

The notifications from TouchDB happened within a transaction for
the -createDocumentFromRevision:error: method, which probably meant
that any database calls happening in the notification callback didn't
see the changes the notification was in response to.

I therefore added a call to the notification handlers when we've
closed the transaction if it was successful.

I think there's still an issue with deleteDocumentById:error: right now,
but it needs further investigation.

RTC 52139
Add notifcation tests for new CRUD API
Set OBJC_DISABLE_GC to allow running tests in Xcode 6

We still allow tests to run on both Xcode 5 and 6.

This means we have to have com.apple.product-type.bundle (which Xcode 5
understands but Xcode 6 likes to change) and the OBJC_DISABLE_GC that
Xcode 6 needs to run the tests.
Fire summary notification when calling -deleteDocumentWithID:error:
Merge pull request #61 from cloudant/34357_index_manager_not_updating

34357 index manager not updating
Fixes CDTDatastore -getRevisionHistory, which was returning an empty array
Passes empty body to CDTDocumentRevision init method so that it doesn't return nil.
Merge pull request #62 from cloudant/35614-CDTDatastore-getRevisionHistory-returns-empty-array

Fixes CDTDatastore -getRevisionHistory, which was returning an empty array
Add NSPredicate query support to Cloudant Sync.
Externalise the error domain for Query builder.
Add CDTQueryBuilderTests to Tests OSX target.
A few objective-c isms

- Don't use valueForKey
- Use convenience constructors
setUp/tearDown need to be at the top of tests.
Move index name and existence validation to common method
Remove declared method that was not implemented from header
Return CDTQueryBuilderResult for NSPredicate to query conversion

Using a dictionary was inappropriate for returning multiple values.
Rename getAllKeyReferences:... to accumulateKeysIntoSet:...
Rework methods to be a little more idiomatic objective-c
Add some tests for triple compound predicates