### Question:
EntityTreeUtilsService { public static EntityTree getDetachedEntityTree(final List<Entity> entities) { return new DetachedEntityTreeImpl(entities); }  static EntityTree getDetachedEntityTree(final List<Entity> entities); List<Entity> getSortedEntities(final EntityTree tree);  }### Answer:
@Test public final void shouldReturnDetachedEntityTree() throws Exception { Entity rootEntity = mockEntityTreeNode(null, 1, "1"); EntityTree entityTree = EntityTreeUtilsService.getDetachedEntityTree(Lists.newArrayList(rootEntity)); Assert.assertEquals(entityTree.getRoot(), rootEntity); Assert.assertEquals(1, entityTree.size()); }