JcrRootNode extends AbstractJcrNode { @Override public AbstractJcrNode getParent() throws ItemNotFoundException, RepositoryException { throw new ItemNotFoundException(); } protected  JcrRootNode( JcrSession session,
                           NodeKey rootNodeKey ); @Override JcrNodeDefinition getDefinition(); @Override boolean isNew(); @Override String getName(); @Override String getPath(); @Override AbstractJcrNode getParent();  }
@Test( expected = ItemNotFoundException.class ) public void shouldHaveNoParent() throws Exception { rootNode.getParent(); }