persist = new PersistenceManager(driver, database, login, password);
// try getting all the objects
SimpleObject pattern = new SimpleObject();
pattern.setCount(3);
List<SimpleObject> obs = persist.getObjects(SimpleObject.class, new GreaterOrEqual(pattern));
assertEquals(2, obs.size());
pattern.setCount(4);
obs = persist.getObjects(SimpleObject.class, new GreaterOrEqual(pattern));
assertEquals(1, obs.size());
pattern.setCount(3);
List<LessSimpleObject> obs2 = persist.getObjects(LessSimpleObject.class, new GreaterOrEqual(pattern));
assertEquals(1, obs2.size());
// assert that two objects are equal if they are the result of the same
// search
List<LessSimpleObject> obs3 = persist.getObjects(LessSimpleObject.class, new GreaterOrEqual(pattern));
assertEquals(obs2.get(0), obs3.get(0));
persist.close();
}