" insert(new Trailer(Trailer.TypeStatus.WAITING));\n" +
"end";
KieHelper helper = new KieHelper();
helper.addContent( drl, ResourceType.DRL );
KieSession ksession = helper.build().newKieSession();
ArrayList<Trailer> trailerList = new ArrayList<Trailer>();
ksession.setGlobal("trailerList", trailerList);
Trailer trailer1 = new Trailer(Trailer.TypeStatus.WAITING);
ksession.insert(trailer1);
// set the agenda groups in reverse order so that stack is preserved
ksession.getAgenda().getAgendaGroup( "Start" ).setFocus();
ksession.getAgenda().getAgendaGroup( "End" ).setFocus();
ksession.getAgenda().getAgendaGroup( "Start" ).setFocus();
ksession.fireAllRules();
assertEquals(2, trailerList.size());
}