@Test
public void testTo() {

    AgendaItemBo data = new AgendaItemBo();
    data.setId("A");
    data.setAgendaId("B");
    data.setVersionNumber(0L);
    data.setRule(getRuleBo("C", "D", "E", "F", null));
    data.setSubAgendaId("G");
    data.setWhenTrue(getAgendaItemBo("H", "I", "J", getRuleBo("K", "L", "M", "N", null)));
    data.setWhenFalse(getAgendaItemBo("O", "P", "Q", getRuleBo("R", "S", "T", "U", null)));
    data.setAlways(getAgendaItemBo("V", "W", "X", getRuleBo("Y", "Z", "AA", "AB", null)));
    AgendaItemDefinition result = testObject.to(data);
    assertEquals("A",result.getId());
    assertEquals("B",result.getAgendaId());
    assertEquals("C",result.getRuleId());
    assertEquals("G",result.getSubAgendaId());
    assertEquals("J",result.getWhenTrueId());
    assertEquals("Q",result.getWhenFalseId());
    assertEquals("X",result.getAlwaysId());
    assertEquals(0L,(long)result.getVersionNumber());
    assertNotNull(result.getRule());
    assertNotNull(result.getWhenTrue());
    assertNotNull(result.getWhenFalse());
    assertNotNull(result.getAlways());
}