01: package org.drools.brms.modeldriven;
02:
03: import junit.framework.TestCase;
04:
05: import org.drools.brms.client.modeldriven.brl.SingleFieldConstraint;
06:
07: public class ConstraintTest extends TestCase {
08:
09: public void testAdd() {
10: final SingleFieldConstraint con = new SingleFieldConstraint();
11: con.addNewConnective();
12:
13: assertEquals(1, con.connectives.length);
14: assertNotNull(con.connectives[0]);
15:
16: con.addNewConnective();
17:
18: assertEquals(2, con.connectives.length);
19: assertNotNull(con.connectives[1]);
20:
21: }
22:
23: }
|