MB-8689 Add support for Couchbase-style purging

This mimics the behaviour for Couchbase style purging, where the
purge sequence in the header matches the highest sequence of the
purged doc_info records. This is meant to be used only in couchdb
standalone unit tests.

Change-Id: Ic0f9c5090128016d479cb45f73cd23afcfb882bd
Reviewed-on: http://review.couchbase.org/27862
Reviewed-by: Volker Mische <volker.mische@gmail.com>
Tested-by: Filipe David Borba Manana <fdmanana@gmail.com>