[Tests] TestRemoteConflictResolution now passes

- Ported ReplicationTest.TestRemoteConflictResolution
- Fixed Puller bug that deleted revisions were not deleted from the
local storage.
Allows for 0 changes to be valid result of Update.
Gateway config now persists data, deeper logging.
Use extension methods, allow Delete to result in 0 changes.
Adds storage engine locks, no longer crashing w/ sigsegv.
Merge pull request #57 from couchbaselabs/replicationtest-testremoteconflictresolution

Port TestRemoteConflictResolution