l.apply();
l.close();
IndexDefinition testDef = new IndexDefinitionImpl("lucene",
TYPE_LUCENE, "/oak:index/lucene");
QueryIndex queryIndex = new LuceneIndex(testDef);
FilterImpl filter = new FilterImpl(null, null);
// filter.restrictPath("/", Filter.PathRestriction.EXACT);
filter.restrictProperty("foo", Operator.EQUAL,
PropertyValues.newString("bar"));
Cursor cursor = queryIndex.query(filter, builder.getNodeState());
assertTrue(cursor.hasNext());
assertEquals("/", cursor.next().getPath());
assertEquals("/a", cursor.next().getPath());
assertEquals("/a/b", cursor.next().getPath());