@Test
public void testOrComposite() throws Exception {
RuleModel m = new RuleModel();
m.name = "or";
CompositeFactPattern cp = new CompositeFactPattern(
CompositeFactPattern.COMPOSITE_TYPE_OR );
FactPattern p1 = new FactPattern( "Person" );
SingleFieldConstraint sf1 = new SingleFieldConstraint( "age" );
sf1.setFactType( "Person" );
sf1.setOperator( "==" );
sf1.setValue( "42" );
p1.addConstraint( sf1 );
cp.addFactPattern( p1 );
FactPattern p2 = new FactPattern( "Person" );
SingleFieldConstraint sf2 = new SingleFieldConstraint( "age" );
sf2.setFactType( "Person" );
sf2.setOperator( "==" );
sf2.setValue( "43" );
p2.addConstraint( sf2 );
cp.addFactPattern( p2 );
m.addLhsItem( cp );
String result = BRDRLPersistence.getInstance().marshal( m );
assertTrue( result