Refactor createDocWithAttachments

didn't actually need this, but will be useful going forward.
Make changes to testContinuousPushReplicationGoesIdleTooSoon2