### Question:
FarmTreeNode extends AbstractEntityTreeNode { @Override public int getChildCount(String nodeId) { return getWikiIds().size(); }  @Override List<String> getChildren(String nodeId, int offset, int limit); @Override int getChildCount(String nodeId);  }### Answer:
@Test public void getChildCount() { assertEquals(3, this.farmTreeNode.getChildCount("anyId")); this.farmTreeNode.getProperties().put("exclusions", new HashSet<>(Arrays.asList("wiki:two", "document:three:Path.To.one", "foo:bar", "space:wiki:three"))); when(this.entityTreeNodeIdConverter.convert(EntityReference.class, "document:three:Path.To.one")) .thenReturn(new DocumentReference("three", Arrays.asList("Path", "To"), "one")); when(this.entityTreeNodeIdConverter.convert(EntityReference.class, "space:wiki:three")) .thenReturn(new SpaceReference("wiki", "three")); assertEquals(2, this.farmTreeNode.getChildCount("anyId")); }