assertEquals(LongAutoID_EINSTEIN, res.get(2).discoverer);
assertEquals(LongAutoID_TESLA, res.get(3).discoverer);
}
public void testJoinSortFields() {
Discovery radioactivity = new Discovery("Radioactivity", LongAutoID_CURIE);
Discovery relativity = new Discovery("Relativity", LongAutoID_EINSTEIN);
Discovery foo = new Discovery("Foo", LongAutoID_EINSTEIN);
Discovery teslaCoil = new Discovery("Tesla Coil", LongAutoID_TESLA);
pm.insert(radioactivity, relativity, foo, teslaCoil).get();
SienaFuture<List<Discovery>> future = pm.createQuery(Discovery.class).join("discoverer", "firstName").order("name").fetch();
List<Discovery> res = future.get();