### Question:
JcrRootNode extends AbstractJcrNode { @Override public final Item getAncestor( int depth ) throws RepositoryException { if (depth == 0) return this; if (depth < 0) { throw new ItemNotFoundException(JcrI18n.noNegativeDepth.text(depth)); } throw new ItemNotFoundException(JcrI18n.tooDeep.text(depth)); } JcrRootNode( SessionCache cache,
                 NodeId nodeId,
                 Location location ); @Override int getDepth(); int getIndex(); String getName(); @Override AbstractJcrNode getParent(); String getPath(); @Override final Item getAncestor( int depth ); @Override void remove(); @Override void removeShare(); @Override void removeSharedSet();  }### Answer:
@Test( expected = ItemNotFoundException.class ) public void shouldNotAllowAncestorDepthGreaterThanNodeDepth() throws Exception { rootNode.getAncestor(1); }