StorageEntryWrapper wrapper = new StorageEntryWrapper(en,
StorageOperation.UPDATE);
this.modifier.updateEntry(wrapper);
ReferenceCounter<StorageQuery> innerQuery = this.controller
.getStorageQuery();
BaseEntry fetchedEntry = innerQuery.get().singleEntryQuery("" + i,
feedId, this.configurator);
assertEquals("updated Title:", insertString, fetchedEntry
.getTitle().getPlainText());
}
// double updates
for (int i = 1; i < this.count; i++) {
Entry e = new Entry();
e.setId("" + i);
String insertString = "Hello world" + i;
e.setTitle(new PlainTextConstruct(insertString));
ServerBaseEntry en = getServerEntry(e);
StorageEntryWrapper wrapper = new StorageEntryWrapper(en,
StorageOperation.UPDATE);
this.modifier.updateEntry(wrapper);
e = new Entry();
e.setId("" + i);
insertString = "Foo Bar" + i;
e.setTitle(new PlainTextConstruct(insertString));
en = getServerEntry(e);
wrapper = new StorageEntryWrapper(en,
StorageOperation.UPDATE);
this.modifier.updateEntry(wrapper);
ReferenceCounter<StorageQuery> innerQuery = this.controller
.getStorageQuery();
BaseEntry fetchedEntry = innerQuery.get().singleEntryQuery("" + i,
feedId, this.configurator);
assertEquals("updated Title:", insertString, fetchedEntry
.getTitle().getPlainText());
}
}