public void testQueryOfLastKnownVersion_shouldWork() throws Exception {
Map<String, EDBObjectEntry> data1v1 = new HashMap<String, EDBObjectEntry>();
putValue("KeyA", "Value A 1", data1v1);
putValue("KeyB", "Value A 1", data1v1);
EDBObject v11 = new EDBObject("/test/object1", data1v1);
EDBCommit ci = getEDBCommit();
ci.insert(v11);
Map<String, EDBObjectEntry> data2v1 = new HashMap<String, EDBObjectEntry>();
putValue("KeyA", "Value A 2", data2v1);
putValue("KeyB", "Value A 1", data2v1);
EDBObject v12 = new EDBObject("/test/object2", data2v1);
ci.insert(v12);
Map<String, EDBObjectEntry> data3v1 = new HashMap<String, EDBObjectEntry>();
putValue("KeyA", "Value A 3", data3v1);
putValue("KeyB", "Value A 1", data3v1);
EDBObject v13 = new EDBObject("/test/object3", data3v1);
ci.insert(v13);
long time1 = db.commit(ci);
ci = getEDBCommit();
Map<String, EDBObjectEntry> data1v2 = new HashMap<String, EDBObjectEntry>();
putValue("KeyA", "Value A 1", data1v2);
putValue("KeyB", "Value A 1", data1v2);
EDBObject v21 = new EDBObject("/test/object1", data1v2);
ci.update(v21);
Map<String, EDBObjectEntry> data2v2 = new HashMap<String, EDBObjectEntry>();
putValue("KeyA", "Value A 2", data2v2);
putValue("KeyB", "Value A 1", data2v2);
EDBObject v22 = new EDBObject("/test/object2", data2v2);
ci.update(v22);
long time2 = db.commit(ci);
ci = getEDBCommit();
Map<String, EDBObjectEntry> data2v3 = new HashMap<String, EDBObjectEntry>();
putValue("KeyA", "Value A 2a", data2v3);
putValue("KeyB", "Value A 1", data2v3);
EDBObject v32 = new EDBObject("/test/object2", data2v3);
ci.update(v32);
Map<String, EDBObjectEntry> data4v1 = new HashMap<String, EDBObjectEntry>();
putValue("KeyA", "Value A 4", data4v1);
putValue("KeyB", "Value A 1", data4v1);
EDBObject v33 = new EDBObject("/test/object4", data4v1);
ci.insert(v33);
long time3 = db.commit(ci);
Map<String, Object> map = new HashMap<String, Object>();
map.put("KeyB", "Value A 1");