}
assertEquals("i", tw.getCurrentNode().getLocalName());
}
public void testParentNode() throws Exception {
TreeWalker tw = new TreeWalkerImpl(dom, NodeFilter.SHOW_ALL, null, false);
// Go to F node
tw.nextNode();
tw.nextNode();
tw.nextNode();
tw.nextNode();
tw.nextNode();
assertEquals("f", tw.getCurrentNode().getLocalName());
assertEquals("d", tw.parentNode().getLocalName());
assertEquals("c", tw.parentNode().getLocalName());
assertEquals("a", tw.parentNode().getLocalName());
assertEquals(null, tw.parentNode());
}