@Test
public void testGetChild()
{

    EntityReference reference = new EntityReference("page", EntityType.DOCUMENT,
        new EntityReference("space", EntityType.SPACE,
            new EntityReference("wiki", EntityType.WIKI)));
    Assert.assertNull(reference.getChild());
    Assert.assertEquals(reference, reference.getParent().getChild());
    Assert.assertEquals(reference, reference.getParent().getParent().getChild().getChild());
}