}
public void testGetQuery() {
// create a resolver with a single map
DataMap m1 = new DataMap();
Query q = new MockQuery("query1");
m1.addQuery(q);
EntityResolver resolver = new EntityResolver(Collections.singleton(m1));
assertSame(q, resolver.getQuery("query1"));
// check that the query added on-the-fly will be recognized
assertNull(resolver.getQuery("query2"));
Query q2 = new MockQuery("query2");
m1.addQuery(q2);
assertSame(q2, resolver.getQuery("query2"));
}