public void anyChildNodeProperty() throws Exception {
Session session = getAdminSession();
Node content = session.getRootNode().addNode("test");
content.addNode("one").addNode("child").setProperty("prop", "hello");
content.addNode("two").addNode("child").setProperty("prop", "hi");
session.save();
String query = "//*[*/@prop = 'hello']";
QueryResult r = session.getWorkspace().getQueryManager().createQuery(
query, "xpath").execute();
NodeIterator it = r.getNodes();
assertTrue(it.hasNext());