@Test
    public void dontPullAttachmentAlreadyPulled() {
        try {
            // create a rev with an attachment, then update it keeping attachment
            // TODO we need to somehow check the attachment wasn't re-downloaded
            createRevisionAndBigTextAttachment();
            pull();
            DocumentRevision docRev1 = datastore.getDocument(id, rev);
            Attachment a1 = datastore.getAttachment(docRev1, bigTextAttachmentName);
            updateRevisionAndKeepAttachment();
            updateRevisionAndKeepAttachment();
            pull();
            DocumentRevision docRev2 = datastore.getDocument(id, rev);
            Attachment a2 = datastore.getAttachment(docRev2, bigTextAttachmentName);
            Assert.assertNotNull(a2);
        } catch (Exception e) {
            Assert.fail("Create/pull error " + e);
        }
    }
@Test
    public void dontPullAttachmentAlreadyPulled() {
        try {
           
           
            createRevisionAndBigTextAttachment();
            pull();
            DocumentRevision docRev1 = datastore.getDocument(id, rev);
            Attachment a1 = datastore.getAttachment(docRev1, bigTextAttachmentName);
            updateRevisionAndKeepAttachment();
            updateRevisionAndKeepAttachment();
            pull();
            DocumentRevision docRev2 = datastore.getDocument(id, rev);
            Attachment a2 = datastore.getAttachment(docRev2, bigTextAttachmentName);
            Assert.assertNotNull(a2);
        } catch (Exception e) {
            Assert.fail("Create/pull error " + e);
        }
    }
@test public void dontpullattachmentalreadypulled() { try { createrevisionandbigtextattachment(); pull(); documentrevision docrev1 = datastore.getdocument(id, rev); attachment a1 = datastore.getattachment(docrev1, bigtextattachmentname); updaterevisionandkeepattachment(); updaterevisionandkeepattachment(); pull(); documentrevision docrev2 = datastore.getdocument(id, rev); attachment a2 = datastore.getattachment(docrev2, bigtextattachmentname); assert.assertnotnull(a2); } catch (exception e) { assert.fail("create/pull error " + e); } }