NodeTypeManagerFacade implements NodeTypeManager { @Override public boolean hasNodeType(String name) throws RepositoryException { return delegate.hasNodeType(name); } NodeTypeManagerFacade(final @NotNull NodeTypeManager delegate); @Override NodeType getNodeType(String nodeTypeName); @Override boolean hasNodeType(String name); @Override NodeTypeIterator getAllNodeTypes(); @Override NodeTypeIterator getPrimaryNodeTypes(); @Override NodeTypeIterator getMixinNodeTypes(); @Override NodeTypeTemplate createNodeTypeTemplate(); @Override NodeTypeTemplate createNodeTypeTemplate(NodeTypeDefinition ntd); @Override NodeDefinitionTemplate createNodeDefinitionTemplate(); @Override PropertyDefinitionTemplate createPropertyDefinitionTemplate(); @Override NodeType registerNodeType(NodeTypeDefinition ntd, boolean allowUpdate); @Override NodeTypeIterator registerNodeTypes(NodeTypeDefinition[] ntds, boolean allowUpdate); @Override void unregisterNodeType(String name); @Override void unregisterNodeTypes(String[] names);  }
@Test public void testHasNodeType() throws Exception { NodeTypeManager delegate = mock(NodeTypeManager.class); NodeTypeManagerFacade facade = getFacade(delegate); final String type = "type"; when(delegate.hasNodeType(type)).thenReturn(true); assertTrue("is true", facade.hasNodeType(type)); }