final AndDescr lhs = rule.getLhs();
assertEquals( 3,
lhs.getDescrs().size() );
PatternDescr pattern = (PatternDescr) lhs.getDescrs().get( 0 );
assertEquals( 1,
pattern.getConstraint().getDescrs().size() );
AndDescr fieldAnd = (AndDescr) pattern.getConstraint();
ExprConstraintDescr fld = (ExprConstraintDescr) fieldAnd.getDescrs().get( 0 );
assertEquals( "bar == false",
fld.getExpression() );
pattern = (PatternDescr) lhs.getDescrs().get( 1 );
assertEquals( 1,
pattern.getConstraint().getDescrs().size() );
fieldAnd = (AndDescr) pattern.getConstraint();
fld = (ExprConstraintDescr) fieldAnd.getDescrs().get( 0 );
assertEquals( "boo > -42",
fld.getText() );
pattern = (PatternDescr) lhs.getDescrs().get( 2 );
assertEquals( 1,
pattern.getConstraint().getDescrs().size() );
fieldAnd = (AndDescr) pattern.getConstraint();
fld = (ExprConstraintDescr) fieldAnd.getDescrs().get( 0 );
assertEquals( "boo > -42.42",
fld.getText() );
}